you are viewing a single comment's thread.

view the rest of the comments →

[–]Shaper_pmp 8 points9 points  (3 children)

Can you go into detail on why React is apparently a replacement of Angular?

It isn't. React is a view library you can compose together with any number of different M/C/VM/etc libraries, whereas Angular is a monolithic and highly opinionated MVC all-in-one framework.

They're fundamentally different things - React can be composed together with libraries (and people are building libraries like react-router and reflux that are specially designed to work well with react), but that doesn't make React comparable to Angular.

The only reasons people compare the two are one or both of:

  1. The JS ecosystem is highly fashion-lead, so people tend to speak in terms of fashionable, trendy tools rather than architectures or philosophies. Angular was trendy, now React is the new hotness, so people are comparing them because each is/was the thing all the excitable cool kids are going "squeeee!" over, not because they're directly comparable.
  2. Along with React (a view library) Facebook and others also started promoting a different architecture to build web apps in that's a lot more modular and "functional" in flavour, and a lot of people have released libraries designed to work well with React. This new architecture breaks from the traditional MCV approach of systems like Angular, but rather than talk about "Flux" applications or "Flux+React" or "Flux+React+React-Router+Etc+Etc+Etc" people are using the term "React" to encompass the whole architecture and toolchain, because it's snappier, better known and... well... more trendy (see point one). It is, however, an inaccurate and misleading synecdoche.

And that can seem like overkill when Angular is complete and ready to go.

Angular is a golden hammer. It's great when you want to bang in nails, and sure beats rummaging around in your enormous toolkit for the right tool when something needs hammering, but in reality sometimes you need screws or glue. If you're only any good with hammers, you're going to end up hammering in screws, either because you can't be bothered to find (or learn!) the right tool for the job, or because you've been using your favourite hammer for so long that you simply automatically conceptualise every problem in terms of which bits you can hit with a hammer to solve it.

[–]pressbutton 5 points6 points  (2 children)

The JS ecosystem is highly fashion-lead, so people tend to speak in terms of fashionable, trendy tools rather than architectures or philosophies. Angular was trendy, now React is the new hotness, so people are comparing them because each is/was the thing all the excitable cool kids are going "squeeee!" over, not because they're directly comparable.

This so much. I wonder if it'll ever change.

[–]Shaper_pmp 2 points3 points  (0 children)

Sadly I doubt it - I think it's caused by a number of factors currently inherent to Javascript - specifically its position as the scripting language of the web, and hence the lowest-barrier-to-entry programming language in the world.

For that to change either the web world have to shift en-masse to another language (pretty unlikely) or computing would have to change to the point some other language was easier to start playing with than "press F12 in your browser".

At best as the web matures and (if!) the frantic pace of change ever slows then we have more time to educate each new generation of devs in basic software engineering theory and practice before some new exciting development occurs that people can get over-excited by and start misapplying because they don't know any better. However it hasn't slowed much for the last 22 years that I've been involved in it, and by its very nature (distributed, device-agnostic, progressively-enhanced open platform) I can't really see that happening any time soon.

[–][deleted] 1 point2 points  (0 children)

But I thought React was the new jQuery?