-
Notifications
You must be signed in to change notification settings - Fork 0
/
webpack.config.js
37 lines (33 loc) · 909 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
const path = require('path');
/*
===========================
WEBPACK CONFIGURATION
===========================
Note: Important to use npm packages of the server
the compiled code will be at dist/main.js
Note2: Babel to write ES 6, as most of my classes are written in new JS
*/
module.exports = {
entry: {
online: './server/client/js/online.js',
teams: './server/client/js/teams.js',
loadcharacters: './server/client/js/loadcharacters.js'
},
mode: 'development',
output: {
filename: '[name].bundle.js',
path: path.resolve(__dirname, 'server/public/dist'),
},
module:{
rules:[
{
test: /\.jsx?$/,
loader: 'babel-loader',
exclude: /node_modules/,
query: {
presets: ['@babel/env']
}
}
]
},
};