Files
keras-js/webpack.prod.config.js
T
2016-08-21 21:36:07 -04:00

35 lines
636 B
JavaScript

const webpack = require('webpack')
module.exports = {
module: {
loaders: [
{
test: /\.js$/,
loaders: ['babel-loader'],
exclude: /node_modules/
}
]
},
output: {
library: 'KerasJS',
libraryTarget: 'umd'
},
resolve: {
extensions: ['', '.js']
},
plugins: [
new webpack.DefinePlugin({
'process.env': {
NODE_ENV: JSON.stringify('production')
}
}),
new webpack.optimize.DedupePlugin(),
new webpack.optimize.OccurenceOrderPlugin(),
new webpack.optimize.UglifyJsPlugin({
compress: {
warnings: false
}
})
]
}