diff --git a/README.md b/README.md index 30f6ca2d1..0fbb4e4b3 100644 --- a/README.md +++ b/README.md @@ -66,6 +66,8 @@ Features * [babel-preset-react-hmre](https://github.com/danmartinez101/babel-preset-react-hmre) for: * react-transform-hmr (HMR for React components) * redbox-react (visible error reporting for React components) + * [babel-plugin-transform-react-constant-elements](https://babeljs.io/docs/plugins/transform-react-constant-elements/) save some memory allocation + * [babel-plugin-transform-react-remove-prop-types](https://github.com/oliviertassinari/babel-plugin-transform-react-remove-prop-types) remove `PropTypes` * [ESLint](http://eslint.org) * Uses [Standard Style](https://github.com/feross/standard) by default, but you're welcome to change this! * Includes separate test-specific `.eslintrc` to support chai assertions diff --git a/build/webpack.config.js b/build/webpack.config.js index 87a2310a9..f423e1503 100644 --- a/build/webpack.config.js +++ b/build/webpack.config.js @@ -126,6 +126,12 @@ webpackConfig.module.loaders = [{ }] }] ] + }, + production: { + plugins: [ + 'transform-react-remove-prop-types', + 'transform-react-constant-elements' + ] } } } diff --git a/package.json b/package.json index ab81a1b6d..6da987b3e 100644 --- a/package.json +++ b/package.json @@ -83,6 +83,8 @@ "babel-eslint": "^5.0.0-beta6", "babel-loader": "^6.2.0", "babel-plugin-react-transform": "^2.0.0", + "babel-plugin-transform-react-constant-elements": "^6.5.0", + "babel-plugin-transform-react-remove-prop-types": "^0.2.2", "babel-plugin-transform-runtime": "^6.3.13", "babel-preset-es2015": "^6.3.13", "babel-preset-react": "^6.3.13",