-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwebpack.config.js
46 lines (42 loc) · 1.4 KB
/
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
44
45
46
/**
* @file Webpack configuration file.
*/
// ━━ IMPORT PACKAGES ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
// » NATIVE PACKAGES
const path = require('path');
// » THIRD PARTIES PACKAGES
// ━━ CONSTANTS ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
// const environment = process.env.NODE_ENV;
// const map_mode = new Map([
// ['development', 'development'],
// ['production', 'production'],
// ['none', 'none'],
// ]);
// ━━ EXPORT MODULE ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
module.exports = {
mode: 'production',
entry: `${__dirname}/src/index`,
target: 'web',
output: {
path: path.resolve(__dirname, 'dist'),
library: {
name: 'Month',
type: 'var',
},
filename: 'month.bundle.js',
},
module: {
rules: [
{
test: /\.js$/,
exclude: /node_modules/,
use: { loader: 'babel-loader' },
},
],
},
plugins: [],
infrastructureLogging: {
level: 'verbose',
},
devtool: 'inline-source-map',
};