You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
836 B
44 lines
836 B
var path = require('path'); |
|
var webpack = require('webpack'); |
|
|
|
module.exports = { |
|
devtool: 'source-map', |
|
entry: [ |
|
|
|
'./client/app' |
|
], |
|
output: { |
|
path: path.join(__dirname, 'dist'), |
|
filename: 'bundle.js', |
|
publicPath: '/static/' |
|
}, |
|
plugins: [ |
|
new webpack.optimize.OccurenceOrderPlugin(), |
|
new webpack.DefinePlugin({ |
|
'process.env': { |
|
'NODE_ENV': "'production'" |
|
} |
|
}), |
|
new webpack.optimize.UglifyJsPlugin({ |
|
compressor: { |
|
warnings: false |
|
} |
|
}) |
|
], |
|
module: { |
|
loaders: [ |
|
// js |
|
{ |
|
test: /\.js$/, |
|
loaders: ['babel'], |
|
include: path.join(__dirname, 'client') |
|
}, |
|
// CSS |
|
{ |
|
test: /\.styl$/, |
|
include: path.join(__dirname, 'client'), |
|
loader: 'style-loader!css-loader!stylus-loader' |
|
} |
|
] |
|
} |
|
};
|
|
|