Why does React require Babel and Webpack to work?

I looked at the vue.js wiki page and saw this:

Compared to React development, Vue can be integrated into an existing web application much easier. Typically, a web application can immediately start using Vue by simply including the Vue.js JavaScript library. Using with Webpack or Browserify is not strictly necessary. This contrasts sharply with the development of React, where use with Webpack and Babel is inevitable, so converting an existing web application is much more complicated.

Can someone explain why React needs a web package and babel? I thought you could just go to the CDN React link and it would work?

+4
source share
2

, Babel Webpack React stack. , Browserify Gulp.

, , Babel Webpack React, :

  • .
  • JSX ES6.
  • .
  • (async/wait) ..

webpack

  • sass, less, postcss ..
  • , , Uglify, HotModuleReplacement, Chunks ..

webpack,

+4

- , React - babel? , CDN React, ?

"babel" "webpack", javascript ES6 JSX ( , HTML JS).

React, , ES6 JSX, Babel, ES6 JSX.

Webpack React, React MattYao.

Vue, JSX html, css JS /, Single File Vue. , - webpack.

0

Source: https://habr.com/ru/post/1673843/


All Articles