-
Notifications
You must be signed in to change notification settings - Fork 1
/
webpack.config.js
43 lines (42 loc) · 894 Bytes
/
webpack.config.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
36
37
38
39
40
41
42
43
const path = require('path');
const webpack = require("webpack");
const packageJSON = require("./package.json");
let plugins = [
new webpack.DefinePlugin({
__VERSION__: JSON.stringify(packageJSON.version),
}),
];
module.exports = () => {
return {
entry: ["./index.js"],
output: {
path: __dirname + "/dist",
filename: "index.js",
sourceMapFilename: "index.js.map",
environment: {
arrowFunction: false,
bigIntLiteral: false,
const: false,
destructuring: false,
dynamicImport: false,
forOf: false,
module: false
}
},
devServer: {
static: {
directory: path.join(__dirname, 'dist'),
},
host: "0.0.0.0",
port: 8079,
},
module: {
rules: [
{ test: /\.js$/,
exclude: /node_modules/,
},
]
}
, plugins
}
};