Home
Crypto
Create
<pre> if you are only using babel to transform jsx to js, this is what you need : <b>installation</b> install babel-cli as global (optional) sudo npm install -g babel-cli install babel-preset-es2015 (optional. if your code using es6 standard) npm install babel-preset-es2015 install babel-preset-react (required) <b>configuration</b> in your root of project, add this file .babelrc and write this to it { "presets": ["es2015", "react"] } or { "presets": ["react"] } <b>run</b> babel source_dir -d target_dir <a href="https://stackoverflow.com/questions/43111618/transform-jsx-to-js-using-babel">https://stackoverflow.com/questions/43111618/transform-jsx-to-js-using-babel</a> #babel #jsx-to-js </pre>