2018-01-25 23:32:53 -06:00
|
|
|
const webpack = require('webpack')
|
|
|
|
const merge = require('webpack-merge')
|
|
|
|
|
2018-01-26 19:22:31 -06:00
|
|
|
const ExtractTextPlugin = require('extract-text-webpack-plugin')
|
2018-01-28 12:34:37 -06:00
|
|
|
const WriteFilePlugin = require('write-file-webpack-plugin')
|
2018-01-26 19:22:31 -06:00
|
|
|
|
2018-01-25 23:32:53 -06:00
|
|
|
const common = require('./webpack.common.js')
|
|
|
|
|
|
|
|
module.exports = merge(common, {
|
2018-01-26 23:20:49 -06:00
|
|
|
entry: {
|
|
|
|
client: ['./client/index.js', 'webpack-hot-middleware/client']
|
|
|
|
},
|
|
|
|
output: {
|
|
|
|
pathinfo: true,
|
|
|
|
publicPath: '/'
|
2018-01-25 23:32:53 -06:00
|
|
|
},
|
|
|
|
plugins: [
|
|
|
|
new webpack.DefinePlugin({
|
|
|
|
'process.env.NODE_ENV': JSON.stringify('development')
|
2018-01-26 19:22:31 -06:00
|
|
|
}),
|
2018-01-26 23:20:49 -06:00
|
|
|
new ExtractTextPlugin({ disable: true }),
|
2018-01-28 12:34:37 -06:00
|
|
|
new WriteFilePlugin(),
|
2018-01-26 23:20:49 -06:00
|
|
|
new webpack.HotModuleReplacementPlugin(),
|
|
|
|
new webpack.WatchIgnorePlugin([
|
|
|
|
/node_modules/
|
|
|
|
])
|
2018-01-25 23:32:53 -06:00
|
|
|
],
|
2018-01-26 23:20:49 -06:00
|
|
|
watch: true
|
2018-01-25 23:32:53 -06:00
|
|
|
})
|