Hey, thank you for taking your time to write this nice tutorial!
I've noticed few things tho:
First:
When you run
npm install --save-dev babel-cli
and then
babel code/index.js -d build/
it will fail if babel-cli is not installed globally (but it would run just fine as "script" from package.json)
Example should be:
./node_modules/.bin/babel code/index.js -d build/
Note: Since it's generally a bad idea to run Babel globally you may want to uninstall the global copy by running npm uninstall --global babel-cli.
Second:
While this line is fine (if we disregard first problem)
babel --presets es2015,stage-0 code/index.js -o build/app.js
In .babelrs
"plugins" should be "presets"
@ljubadr Thanks for opening this issue, I am aware of the problems in this tutorial, thanks for mentioning these problems, I am aware of some more problems too, and will surely solve them as soon as possible. :+1:
Hey, thank you for taking your time to write this nice tutorial!
I've noticed few things tho:
First: When you run
npm install --save-dev babel-cli
and thenbabel code/index.js -d build/
it will fail if babel-cli is not installed globally (but it would run just fine as "script" from package.json)Example should be:
./node_modules/.bin/babel code/index.js -d build/
On babeljs website (https://babeljs.io/docs/setup/#babel_cli) I found this very useful (as it prevents cases like this)
Second: While this line is fine (if we disregard first problem)
babel --presets es2015,stage-0 code/index.js -o build/app.js
In .babelrs"plugins" should be "presets"
Anyway, thanks again
Cheers