mirror of
https://github.com/zoriya/react-native-web.git
synced 2026-05-25 23:48:54 +00:00
Smaller production builds
Builds on the exclusion of PropTypes from production builds: - Remove 'lodash' and use smaller modules for equivalent functions. - Remove use of some unnecessary Facebook utilities. - Remove 'TouchableBounce'; it isn't part of React Native anymore. - Remove stray import of 'react-dom/server'. - Exclude 'StyleSheetValidation' from production. Measuring the UMD build (gzip)… Before: ~100KB After: ~60KB
This commit is contained in:
+4
-1
@@ -25,7 +25,10 @@ module.exports = {
|
||||
path: DIST_DIRECTORY
|
||||
},
|
||||
plugins: [
|
||||
new BundleAnalyzerPlugin({ analyzerMode: 'static' }),
|
||||
new BundleAnalyzerPlugin({
|
||||
analyzerMode: 'static',
|
||||
openAnalyzer: false
|
||||
}),
|
||||
new webpack.DefinePlugin({ 'process.env.NODE_ENV': JSON.stringify('production') }),
|
||||
new webpack.optimize.DedupePlugin(),
|
||||
// https://github.com/animatedjs/animated/issues/40
|
||||
|
||||
Reference in New Issue
Block a user