Ranked in these QuestionsQuestion Ranking
Pro Can be used with any front-end stack
Vue can easily be integrated with other front-end libraries. This makes it an extremely versatile tool and it's easy to fix its shortcomings or missing features by just plugging in another library.
Pro Single file component
Vue.js weighs in at 16kb min+gzip.
Pro CLI and Webpack integration
Pro Responsive server-side rendering
Since most of the mainstream server-side rendering implementations are synchronous, they can block the server's event loop when the application is complex.
Vue implements streaming server-side rendering, which allows you to render your component, get a readable stream and directly pipe that to the HTTP response. This allows you to have a responsive server and decreases the time your users have to wait before they get your rendered content.
Pro Supports inline templating
Pro Can be made even lighter
Since the template-to-virtual-DOM and compiler can be separated, you can compile the templates in your machine and then deploying only the interpreter which is 12KB minified and gzipped.
Pro Support for both templates and JSX
You can choose to use either a templating language, or if you feel it's necessary to drop on a lower virtual-dom level, you can use JSX. This is simply done by replacing the
template option with a
Or alternatively, you can embed functions inside templates by using the
Pro Vuex store, events system
Pro SEO friendly
Starting with Vue 2.0, Vue supports server-side rendering. This helps with SEO a lot, since the views are rendered directly on the server, which are indexed by search engines.
Pro Reactivity system
Pro Easy to reuse components
Pro Virtual DOM support
Instead of relying on the DOM, React implements a virtual DOM from scratch, allowing it to calculate precisely what needs to be patched during the next screen refresh. This is orders of magnitude faster than fiddling with the DOM itself.
Pro Supported by Facebook and Instagram
React is built by Facebook engineers initially to be used only for their inner projects especially to solve the problem of building large complex applications with constantly changing data.
Pro Easy to write tests
Pro Tested on Facebook itself
React is used on one of the most visited websites on the planet, Facebook. With stellar results and with million of people experiencing it every day.
Pro Can be used with different libraries
Pro One-way data flow
React's one-way data binding (or one-way data flow) means that it's easy to see where and how your UI is updated and where you need to make changes. It's also very easy to keep everything modular, fast and well-organized.
Pro Extensive SVG support
Since React v0.15, SVG is fully supported. React supports all SVG attributes that are recognized by today's browsers.
Pro Template engine independent
React provides a template engine (JSX) which is easy to use. But it's not mandatory.
Pro Flux architecture pattern
Flux is a platform agnostic pattern which can technically be used with any application or programming language.
One of Flux' main features is that it enforces uni-directional data flow which means that views do not change the data directly.
With React this is useful because this way it's easier to understand an application as it starts getting more complicated. By having two-way data binding, lead to unpredictable changes, where changing one model's data would end up updating another model. By using the Flux architecture, this can be avoided.
Pro Good debugging tools
React has an official Chrome Extension which is used as a developing and debugging tool. It can be used to quickly and painlessly debug your application or view the whole application structure as it's rendered.
Pro Server side rendering
React can render it's components and data server side, then it sends those components as HTML to the browser.
This ensures faster initial loading time and SEO friendliness out of the box, since it's indexed as any other static website by search engines.
Con Very enterpris-ey in design and tooling
Con Poor typescript support
Very basic typescript support.
Con Large file size
React's react.min.js is 145.5KB in size. It's much larger than some other libraries that offer roughly the same features and it's almost the same size as some MV* frameworks such as Angular or Ember that offer more features out of the box.
Although, it should be mentioned that sometimes having a smaller library may force developers to reinvent the wheel and write inefficient implementations on features that React already has. Ending up with a larger application that's harder to maintain and/or that has bad performance.
Con You have to learn a new syntax
Requires to learn a custom syntax, JSX that has some gotchas and introduce complexity, a steeper learning curve, and incompatibility with other tools.
Though you can opt out from JSX and use vanilla JS instead. But that is not recommended since it adds a lot of unneeded complexity which JSX tries to avoid.
Con Dependency hell
Con No support for legacy browsers
React has recently dropped support for Internet Explorer 8. While the library may still work on IE8, issues that affect only IE8 will not be prioritized and/or solved.
Con Slow VirtualDOM
React's VirtualDOM is relatively slow compared to other libraries that implement a VDOM.