-
Notifications
You must be signed in to change notification settings - Fork 1
/
webpack.config.js
43 lines (41 loc) · 927 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
const path = require('path');
const webpack = require('webpack');
module.exports = {
cache: true,
context: path.resolve(__dirname, './src'),
devtool: 'source-map',
entry: ['./index.js'],
externals: {},
mode: 'production',
name: 'GitBot',
node: {
Buffer: true,
console: true,
global: true,
nodeBuiltin: true,
process: true,
setImmediate: true,
__filename: true,
__dirname: true,
},
optimization: {
nodeEnv: 'production',
minimize: false,
},
output: {
auxiliaryComment: '(c) 2019 devlato <[email protected]>',
filename: 'index.bundle.js',
path: path.resolve(__dirname, './build'),
},
parallelism: 4,
plugins: [new webpack.EnvironmentPlugin(['NODE_ENV'])],
profile: true,
resolve: {
extensions: ['.js', '.json'],
modules: [path.resolve(__dirname, './node_modules')],
},
stats: {
colors: true,
},
target: 'async-node',
};