News for hackers. Stuff that matters.
Re:Angular 9.0 by mattlondon on Friday February 07, 2020 @04:25AM (#22264406)
I have not done much react apart from a "hello world", but I have been using Angular2+ for years, having previously used AngularJS. Here are a few thoughts:

The learning curve is steep I agree. There does feel like there is a lot of ceremony and boilerplate required for even the more basic "hello world". Also if you are not familiar with RxJS before learning Angular then that is a second learning curve that you need to know too and it is a challenge.

The docs are also very frustrating:

- the API reference is usually just auto-generated with perhaps a single sentence saying "The FooBarDooDad does foo to bar" with zero other content, e.g. https://angular.io/api/core/Query

- the tutorial guides are absolutely huge epic documents, scrolling screen after screen after screen after screen and are far too long and far too convoluted to be useful in my opinion. It feels like they are several entire chapters lifted from a printed book or something, rather than something useful for a developer trying to implement something. E.g. https://angular.io/tutorial/toh-pt6 (and that is just part 6!) I've been doing this for years and I still hate having to go back to those docs.

- the tutorials are all talking about some "Heros" app that I have no idea what it is or what it is doing. I wish they just had examples for the simplest-possible case in stackblitz-widgets that does not need me to know the ins-and-outs of their sample app.

That said, once you are up and running with Angular I have found it is very easy to use, and RxJS is really nice once you get your head around it. Everything works largely as expected, and you can more or less forget about Angular and concentrate on the logic. As far as boilerplate goes, I have found that once you have done the boilerplate once, you just copy-paste from one file to another then do a search-replace for the name etc - takes perhaps 10 seconds etc before you are writing logic.

I would like the Angular team to add some sort of "official" state management feature though in the future. In my view, it is the biggest missing gap in the library and you either have to use NgRX as a separate library, or have to botch a global app state by using either a Service or a convoluted @Input/@Output chain

Re:Angular 9.0 by qwerty456127 on Friday February 07, 2020 @05:17AM (#22264640)
> Also if you are not familiar with RxJS before learning Angular then that is a second learning curve that you need to know too and it is a challenge.

You are not the only one mentioning this here. Do you believe it's wise to start with learning RxJS before you even approach Angular if you are a VanillaJS/JQuery "dinosaur" looking forward to learn Angular?

Re:Angular 9.0 by DonHopkins on Friday February 07, 2020 @06:58AM (#22265160)
RxJS is very cool and well designed, and stands on its own. Worth learning about even if you don't use Angular, but definitely if you do! The basics are easy to understand, but there are a whole lot of deep profound operators that it will take a long time to master, although you don't need them all at first.

https://rxjs-dev.firebaseapp.com/api

Reading the guide and pondering the following table helped me understand how other mechanisms in JavaScript work together and relate to each other, and the corner that Observable occupies:

https://rxjs-dev.firebaseapp.com/guide/observable

>Observables are lazy Push collections of multiple values. They fill the missing spot in the following table:

            SINGLE      MULTIPLE
    Pull:   Function    Iterator
    Push:   Promise     Observable
Re:Angular 9.0 by WA on Friday February 07, 2020 @11:42AM (#22267747)
RxJS is not made for normal people. You have to be some brainy CS wizard to get it. If you're used to more traditional "linear" coding (no matter if functional or procedural), RxJS is a brainfuck with its time/stream component. I hated it when I tried to use it.
Re:Angular 9.0 by DonHopkins on Friday February 07, 2020 @12:38PM (#22268506)
That's what I meant by "very cool"! ;)
Re:Angular 9.0 by mattlondon on Friday February 07, 2020 @06:30AM (#22265010)
Yep it might help to learn some RxJS "in isolation" before encountering it for potentially the first time in Angular.

No need to master it - probably spend an hour or two on RxJS tutorials & samples to get to know it before jumping in with Angular so you know where the join is between Angular + RxJS.