-
Notifications
You must be signed in to change notification settings - Fork 21
Expand file tree
/
Copy pathwebpack.dev.config.js
More file actions
57 lines (56 loc) · 1.66 KB
/
webpack.dev.config.js
File metadata and controls
57 lines (56 loc) · 1.66 KB
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
const path = require("path"),
HtmlWebpackPlugin = require("html-webpack-plugin"),
ESLintPlugin = require("eslint-webpack-plugin");
module.exports = {
context : path.resolve(__dirname),
devtool : "inline-source-map",
// devServer : {
// static : path.resolve(__dirname, "/dist")
// },
optimization : {
runtimeChunk : "single"
},
mode : "development",
entry : {
voice_call : "./src/voice_call/script.js",
video_call : "./src/video_call/script.js"
},
resolve : {
alias : {
"@" : path.resolve(__dirname, "src")
}
},
plugins : [
new HtmlWebpackPlugin({
inject : true,
publicPath : "/",
title : "Index",
template : "./src/index.html",
filename : "index.html",
chunks : []
}),
new HtmlWebpackPlugin({
inject : "body",
publicPath : "/",
title : "Voice Call",
template : "./src/voice_call/index.html",
filename : "voice_call.html",
chunks : ["voice_call"]
}),
new HtmlWebpackPlugin({
inject : "body",
publicPath : "/",
title : "Video Call",
template : "./src/video_call/index.html",
filename : "video_call.html",
chunks : ["video_call"]
}),
new ESLintPlugin({})
],
output : {
filename : "[name].bundle.js",
path : path.resolve(__dirname, "dist"),
clean : true,
publicPath : "/"
}
};