UNPKG

mach

Version:
40 lines (31 loc) 573 B
var webpack = require('webpack'); var plugins = [ new webpack.DefinePlugin({ 'process.env.NODE_ENV': JSON.stringify(process.env.NODE_ENV) }) ]; if (process.env.COMPRESS) { plugins.push( new webpack.optimize.UglifyJsPlugin({ compressor: { warnings: false } }) ); } module.exports = { output: { library: 'mach', libraryTarget: 'umd' }, module: { loaders: [ { test: /\.js$/, exclude: /node_modules/, loader: 'babel' } ] }, node: { buffer: false, process: false }, plugins: plugins };