Does Webpack Make Es6 Modules Compatible With Es5 Browsers?
Solution 1:
Does this mean that I can use ES6 modules and due to the transformation of webpack they will also work in old browsers that do not support ES6 modules?
This is one of the purposes of Webpack.
Whats the difference between this transformation webpack does and that one babel does?
Webpack is a bundler. Babel is a transpiler. They are supposed to be used together. Babel transform-es2015-modules-commonjs
transformation transforms ES modules into CommonJS modules. CommonJS modules are supported in Node.js but not in browsers.
What are the advantages/disadvantages using babel or webpack concerning ES6 module compatibilty in older browsers?
The advantage is that you can use ES modules in older browsers. The disadvantage is that Webpack may introduce limitations like how circular dependencies can be handled.
Post a Comment for "Does Webpack Make Es6 Modules Compatible With Es5 Browsers?"