DEV Community 👩‍💻👨‍💻

Discussion on: React Js Vs Angular Which is Better ?

curiousdev profile image

I am very thankful for your detailed and insightful response!
One of the reasons, why I am aware of Web Development and interested of it is, that I had to work with "projects" (implementation of components extending another product), which are basically using web technologies, but not traditional Web Development, like creating complete websites/applications for visitors or the company itself. This led me to have a closer look at Vue, which you mentioned, but I also tried React for other reasons.
Please let me add to my initial question, that I just wanted to know features etc., that would make you have to use a framework, because of specific requirements. But you answered this later well, thanks. The comparison of Angular and React helps a lot, too!
Also I agree a lot on the part regarding the choice of technologies, which describes, that you possibly have to use, what already is in use. This is something I have experienced. People learning development should be prepared for this, if they want to work and develop. It is not bad to start learning with something well known and being able to use the knowledge for other similar technologies in a project, if this should be the case.

Thread Thread
peerreynders profile image
peerreynders • Edited on

It is not bad to start learning with something well known and being able to use the knowledge for other similar technologies in a project.

In this context we are talking about frameworks which have very different opinions (even the React component runtime is an opinion) on how to abstract over the web which often leads to accusations of:

  • Angular being unnecessarily bloated.
  • React unnecessarily re-implementing existing browser capabilities (e.g. the synthetic event system; it's only going to get worse with React Server Components; if you don't need React native consider using Preact instead; e.g. Etsy).

The point I'm trying to make is that learning to use a framework doesn't create a sense of the constraints the web has to operate under (native apps have it much easier); thus to the untrained eye it's not always obvious which tradeoffs are being made by any particular framework. So learning one framework may make it easier to learn the next framework but "understanding what makes the web work" isn't a given. Having a framework-centric view of web development can lead to products that behave like this in the real world.

If web development (e.g. What is a web developer?, video) was organized as a trade with an apprenticeship it could introduce developers to the whole range of available rendering options:

  • How to use HTML/CSS to create a static page
  • How to use JavaScript to add interactivity
  • How to use a static site generator (SSG) to generate an entire site
  • How to structure a server rendered site with dynamic content
  • How to use CSR framework for richer interactivity
  • How to use SSR to improve the experience of CSR applications

With that kind of spectrum of experience it would be much clearer when it is appropriate to use what technology. Instead people seem to exist at either end of that list leading to The Great Divide.

While it is true that frameworks can make developer's lives easier and more productive it doesn't change that:

  • The web is the most hostile development platform in the world (especially for resource constrained devices).
  • The web isn't one environment but a wide spectrum of uncountable combinations of client device capabilities, network conditions and server platforms/technologies. And web-based solutions cover the whole spectrum from documents to applications.
Thread Thread
optimisedu profile image

Great post
Main point from this which I will expand on: Learn the fundamentals and write for your usecase.

So angular is batteries included as you said. It also employs two way data binding and when badly written can be an objective mess.

You need to understand their lingo to make apps which are nice and performant after the initial load time.

Social workers for a pwa come included. That can be great, with both frameworks you need to think small and work up with a plan.

Angular is pretty opinionated which can be nice, or can be a bit overwhelming.

That said jsx takes a bit of a paradigm shift to work with which many people prefer.

They are both very heavy platforms which I feel are overused. They have definite usecases but if your project is small don't add thosands of dependency files. It's not a case of is X or Y better. Aim to know when it is best to use X Y Z or just vanilla sprinklings.

My 0.02