Angular vs React vs Vue 👀

·

2 min read

A simple comparison...

Angular is a framework, while React and Vue are libraries, therefore angular is heavier than the other two, due to its big codebase. The Angular’s core contains most of the functionalities you might need in your application, while with React and Vue, you have to find external libraries, maintained by probably, independent contributors. Therefore, when working with React and Vue, you have to be more careful when choosing libraries, being aware that libraries with a poor maintenance might be deprecated in future.

Coding style

To build an app with Angular you have to learn Typescript, which is a superset of JavaScript, while with Vue and React you can use pure JS. Regarding the view, with Angular and Vue you write it with HTML, where in React you have to write JSX, which is a syntax that allows coexistence between HTML and JS. Thus, Angular and Vue are ideal if you want to reuse HTML from a huge codebase.

Model

Vue and React use a Virtual DOM (VDOM), which is a node tree listing content, and elements and their attribute as objects and properties. The browser DOM is not updated directly but instead, they use the VDOM as abstraction layer. On the other hand, Angular is based on the MVC pattern and manipulates the DOM directly. Changes in your application will update it without any middleware.

State

As common, when creating our apps, the components will have their scoped state, and Angular, and Vue works in a way that the data is mutable. User inputs and code can modify the state directly. In React, the state is immutable. To update it, you have to use a specific function that will do it asynchronously.

Community

Angular and React have a powerful community behind. Angular was created by Google, and React by Facebook. Therefore, both have longer life expectancy. Whereas Vue, is an open source project, created by Evan You. Nevertheless, Vue gained a huge fame, because the creator’s idea was to take the best of the other two. From Angular, it took similar templates with good syntax, and from React, it got many features, specially the component-based approach. Vue is actively maintained, with almost 300 contributors and supported by many big companies.