Browse Source

Merge pull request #5686 from vitorbal/master

Improve documentation for using React with Webpack
main
Paul O’Shannessy 9 years ago
parent
commit
0798e6415e
  1. 9
      docs/getting-started.md

9
docs/getting-started.md

@ -45,6 +45,15 @@ $ webpack
>
> If you are using ES2015, you will want to also use the `babel-preset-es2015` package.
**Note:** by default, React will be in development mode, which is slower, and not advised for production. To use React in production mode, set the environment variable `NODE_ENV` to `production` (using envify or webpack's DefinePlugin). For example:
```js
new webpack.DefinePlugin({
"process.env": {
NODE_ENV: JSON.stringify("production")
}
});
```
## Quick Start Without npm

Loading…
Cancel
Save