DEV Community

Discussion on: How Angular Works, and Why You Should Be Using It.

Collapse
 
leob profile image
leob

The elephant in the room is of course React - why use Angular when React is so totally dominant nowadays, in which scenarios is Angular a better choice?

Collapse
 
frangiskos profile image
Frangiskos

Angular is a better choice for large-scale projects with many developers working on the same project. Not all developers have the same expertise or code in the same way. Angular is an opinionated framework that guides everyone to write in the same way.

Collapse
 
leob profile image
leob

Yep that's what I gathered ... on the other hand, if the devs on a project already know React (and not Angular) then the story obviously becomes different already - and you could argue that React has also become somewhat more "opinionated" over the years - everybody seems to have converged on using Hooks now, to name an example, and things like routing and so on have effectively become part of the "core" tool.

Thread Thread
 
edarioq profile image
Edgar Quintero • Edited

It's also a hiring question. React being so dominant (because it's simpler) makes building and keeping a team a lot easier. There is no question that Angular can run laps around React when it comes to software quality, utiliy, scalability, maintainability. But if it's easier to pick up, code with, and get something written faster, then companies will prefer it always... Never the engineers that know better. :)

Thread Thread
 
leob profile image
leob

That's what I also think, React has become so dominant, everything else (Vue, Angular) is pretty niche ... it also means that the React ecosystem is a lot bigger, and so on. Yeah well to be honest I think this race is over ...

Thread Thread
 
ashleyjsheridan profile image
Ashley Sheridan

It's a bit simplistic to ignore any framework/library just because it's not popular. If that were a good argument, there would be no need for MacOS or Linux on the desktop, because Windows is more popular, there would be no need for iOS because Android is more popular, etc.

It all comes down to what is the best tool for the job, and that itself is answered through further questions:

  • What is the scale of the project?
  • What is the team already familiar with?
  • What would the initial cost? (in terms of time, etc) be to learn a new tool/library/framework?
  • What would be the ongoing cost? (in terms of ease of maintenance for future work, etc)

I've been using Angular for about 6 years now, and the scale of the largest project I'm working on with it I don't think would be as simple or as clean were I to do in React. That codebase is almost 40,000 lines of code (although a little over half of that is unit/acceptance test code).

Thread Thread
 
leob profile image
leob

Totally agree, just seems that React is getting ever more dominant, not saying that that's a good thing per se but it seems to be the case ...

Collapse
 
chadwinjdeysel profile image
Chadwin Deysel

Hi Leob. Thanks for mentioning React. Answering your question could be a separate post entirely (and there are many "Angular vs React" posts out there). To me however, the short answer comes down to personal preference and what you want to build.

In my opinion, while you can use React for larger scale applications, it's better suited for smaller applications or websites that needs to get the most out of SEO because of the GatsbyJS and NextJS libraries. Angular is just much better suited for larger scale applications because of the way it structures it's code and all the things it includes the moment you create a new application (routing, reactive forms, RxJS etc).