mirror of
https://github.com/zoriya/react-native-web.git
synced 2026-05-25 15:42:24 +00:00
[change] Use animatedjs/animated
Depend on 'animatedjs/animated' for the Animation implementation. This patch also replaces 'es6-set' with a small shim to reduce impact on production bundle size. Fix #95
This commit is contained in:
+8
-2
@@ -1,4 +1,5 @@
|
||||
var webpack = require('webpack')
|
||||
const path = require('path')
|
||||
const webpack = require('webpack')
|
||||
|
||||
const DIST_DIRECTORY = './dist'
|
||||
|
||||
@@ -8,13 +9,18 @@ module.exports = {
|
||||
},
|
||||
output: {
|
||||
filename: 'ReactNative.js',
|
||||
library: 'React',
|
||||
library: 'ReactNative',
|
||||
libraryTarget: 'umd',
|
||||
path: DIST_DIRECTORY
|
||||
},
|
||||
plugins: [
|
||||
new webpack.DefinePlugin({ 'process.env.NODE_ENV': JSON.stringify('production') }),
|
||||
new webpack.optimize.DedupePlugin(),
|
||||
// https://github.com/animatedjs/animated/issues/40
|
||||
new webpack.NormalModuleReplacementPlugin(
|
||||
/es6-set/,
|
||||
path.join(__dirname, 'src/modules/polyfills/Set.js')
|
||||
),
|
||||
new webpack.optimize.OccurenceOrderPlugin(),
|
||||
new webpack.optimize.UglifyJsPlugin({
|
||||
compress: {
|
||||
|
||||
Reference in New Issue
Block a user