mirror of
https://github.com/ruanyf/es6tutorial.git
synced 2025-05-24 18:32:22 +00:00
fix bug to remove unnecessary preset
This commit is contained in:
parent
f7494bc67e
commit
9c5d80d3ff
@ -395,7 +395,7 @@ $ npm install --save-dev babelify babel-preset-es2015
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
$ browserify script.js -o bundle.js \
|
$ browserify script.js -o bundle.js \
|
||||||
-t [ babelify --presets [ es2015 react ] ]
|
-t [ babelify --presets [ es2015 ] ]
|
||||||
```
|
```
|
||||||
|
|
||||||
上面代码将ES6脚本`script.js`,转为`bundle.js`,浏览器直接加载后者就可以了。
|
上面代码将ES6脚本`script.js`,转为`bundle.js`,浏览器直接加载后者就可以了。
|
||||||
|
Loading…
x
Reference in New Issue
Block a user