-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdev.js
35 lines (24 loc) · 787 Bytes
/
dev.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
const webpackMerge = require('webpack-merge');
const commonConfig = require('./base.js');
var webpack = require('webpack');
var path = require('path');
module.exports = function (env) {
return webpackMerge(commonConfig(),{
devtool: "cheap-eval-source-map",
entry:{
webpack_hot:'webpack/hot/only-dev-server'
},
devServer: {
hot: true,
// contentBase: path.join(__dirname, "dist"),
compress: true,
port: 9000,
host: "0.0.0.0",
historyApiFallback: true
},
plugins: [
new webpack.NamedModulesPlugin(),
new webpack.HotModuleReplacementPlugin(),
]
})
}