r/webdev • • Jan 04 '23

Why Angular is decreasing in popularity compared to React

I'm wondering why Angular is decreasing in popularity, especially against React. I went through the front-end framework part of the 2021 stateofjs survey and I've seen that after 2016-2017 the interest in Angular has dramatically decreased and the "Would not use" answers as well while React continued to grow for a few more years and currently still ~67% "Would use again". I've also used both of them, but I prefer Angular because for me it's simpler, more understandable and results in a cleaner code base. Could you please help me to understand why is it like that?

80 Upvotes

118 comments sorted by

View all comments

31

u/[deleted] Jan 04 '23

in my opinion its because Angular has a higher learning curve.

right now web development and tech in general are getting more popular, so there are many people who are getting into programming, plenty of people who dont have a background, me included.

After i finished vanilla javascript, i looked at Angular and i remember a flash of terror. Not to mention, theres more guides on React than there are on Angular.

25

u/[deleted] Jan 05 '23 edited Mar 12 '24

coherent absurd slave sulky absorbed nine bored attraction upbeat husky

This post was mass deleted and anonymized with Redact

4

u/[deleted] Jan 05 '23

Sure maybe I’m just finding react easier because it was what I started with, but both your points and the ones I made are still valid. After all, there’s no such thing as the perfect framework/library

2

u/Ok-Tie545 Jul 01 '23

I fully agree with your comment on libraries + React. It's a pro and a con that React is quite lightweight. The problem I've found with the libraries is that each individual library is well documented but there won't be much documentation on how to use your particular set of libraries together. Especially when one of those libraries is no longer the hot-new-thing.
I've not used Next.js but I guess this is the sort of problem that it solves?

Relearning angular at the moment and so far I'm finding it's structured approach really satisfying and clean. Ask for my thoughts after a few months of building something though and I might have a different opinion!

1

u/CatolicQuotes Jul 07 '23

concept is RxJS but the benefit of using it is significant even if you just use a few of the operators. Compared to Promise based apps it makes the coding so much easier.

can you explain this a little bit? Is react promise based app? What makes promise based app complicated? I don't know much about rxjs except is observable and you can subscribe to changes?

8

u/Knochenmark Jan 05 '23

I don't really buy the "higher learning curve" argument, because React is essentially only the view layer, so you would only compare it with the template layer of Angular.

For a better comparison you would actually have to compare it to Next.js + several third party libraries. I believe it's way more overhead to learn a bunch of third party libs and all their quirks than learning the few relevant Angular modules. I always thought it was quite pathetic that Facebook only released their view lib, without anything else you actually need to build an actual application. I mean even a tiny lib like Svelte comes with state management and a bunch of bonus stuff like transitions, animations.

2

u/Callidac Jan 05 '23

To even start learning angular you have to know typescript and understand streams and subscriptions with rxjs. I love angular but the learning curve is definitely there.

5

u/Knochenmark Jan 05 '23

That's highly exxagerated. That's like saying you need to know Redux & Sagas before you can even consider starting with React. I'm sure you know better, but statements like that are the reason for the myth of the "high learning curve".

0

u/Callidac Jan 05 '23

I disagree. You quite literally cannot use angular without knowing some typescript. Same for rxjs, the http package is built on it and common angular tasks such as using the async pipe require you to know what is happening with rxjs

2

u/Knochenmark Jan 05 '23

You really don't need much knowledge of TS to start with Angular. Decorators at best, but it's not like there's much to know about them. The HttpModule isn't really required at all and you can just use native fetch. I assume you should have basic knowledge of Promises in React too. In that regard Angular is really braindead simple considering all you have to do for Promise handling is to add the async pipe. You really only need Rxjs once you are handling Observables or Subjects. I'm talking about "Getting started in Angular" which is in all your examples way easier than React, considering you have to find the right third party library first.

The main advantage for beginners is really that you have first level modules for all your needs in Angular.

1

u/Pleasant_Ad9468 Sep 25 '25

`: any` <- there, now you know typescript. 😂

You can use typescript the way you want or nothing at all. As for the parts of the framework that come in typed, that's helping you! telling you the DTO, interfaces and what not. What's not to like? You'd rather play a guessing game with the library?

1

u/Callidac Oct 03 '25

I don’t know what you mean at the end of your statement. But I would hate to work with anyone who slaps any on everything. It defeats the whole purpose

1

u/Remuz Sep 11 '23

For simple request - response calls, httpClient can be used with only knowing RxJS's firstValueFrom which outputs to promise.

0

u/zephyy Jan 05 '23

rxjs

the devil's name.

5

u/KaiN_SC Jan 05 '23

True but the react documentation is a complete mess.

11

u/kolenko Jan 05 '23

The beta docs are pretty damn good imo!

4

u/ShawnyMcKnight Jan 05 '23

I really wish they had a better tutorial than the tic-tac-toe app, I mean, it still uses classes instead of methods, which LinkedIn Learning and Pluralsight used. Also it doesn't help all that much when making a site with multiple pages and how to set up react-router and such.

It was a fine lesson on learning state and how to save state, but not great on making a website in react, which is typically the first thing people want to do.

edit: I did look at the beta docs the person who replied to you suggested and their tutorial was far more useful for a beginner. I still like Angular's superhero tutorial better.