离线转义 reactjs JSX

Offline Transform

First install the Babel command-line tools (requires npm):

npm install --global babel-cli npm install babel-preset-react

Then, translate your src/helloworld.js file to plain JavaScript:

babel --presets react src --watch --out-dir build

Note:

If you are using ES2015, you will want to also use the babel-preset-es2015 package.


你可能感兴趣的:(reactjs,JSX)