Re:Angular 2 Final Released
by xeromal on Thursday September 15, 2016 @01:25AM
(#12503653)
Obtuse error logging is my biggest problem. A lot of the times you have no idea what's going wrong.
[ Parent
| on HN ]
Re:Angular 2 Final Released
by mattmanser on Thursday September 15, 2016 @04:39AM
(#12504379)
That's a general javascript problem though as soon as you involve any third party library.
Something funky going wrong when jQuery's involved? Good luck stepping through that.
This is the reason why I've been separating recent projects into two webpack bundles.
I put all libraries into a common bundle, which I blackbox in the browser debugger. This way only frames from my own code show up in the stack by default, and the debugger won't step into library code.
This also makes stack traces very easy to visually parse, as you can pretty much ignore all the ones ending in "... (common.js)".
Re:Angular 2 Final Released
by JesseObrien on Thursday September 15, 2016 @01:27PM
(#12508041)
React actually does a fabulous job of spitting out very readable error messages. It removes so many debug cycles from development that it alone is worth switching.
Re:Angular 2 Final Released
by mattmanser on Thursday September 15, 2016 @07:22PM
(#12510686)
Anything that 'spits out' readable error messages in javascript hijacks the error stack.
Which is doubly shit.
May want to give Sentry a try for error logging: sentry.io/for/angular2
Let us know if there's anything we can be doing better :)
That's pretty slick. Thanks for sharing.
Right now, some of the Angular 2 error messages are cryptic - I find it very difficult to figure out what goes wrong in tests currently with Angular 2, the only utility of some of the error messages end up being that there is an error in Angular's compilation of a component (for example).