-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathwebpack.config.js
61 lines (59 loc) · 2.04 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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
/* This file is part of eol-tracker.
*
* Copyright © 2020 Datto, Inc.
* Author: Dakota Williams <[email protected]>
*
* Licensed under the GNU Lesser General Public License Version 3
* Fedora-License-Identifier: LGPLv3+
* SPDX-2.0-License-Identifier: LGPL-3.0+
* SPDX-3.0-License-Identifier: LGPL-3.0-or-later
*
* eol-tracker is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* eol-tracker is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with eol-tracker. If not, see <https://www.gnu.org/licenses/>.
*/
const path = require('path');
module.exports = {
entry: './js/timeline.js',
mode: 'none',
output: {
filename: 'main.js',
path: path.resolve(__dirname, 'root/static/js'),
libraryTarget: 'var',
library: 'EOLTracker',
},
module: {
rules: [
{
test: /node_modules[\\\/]vis[\\\/].*\.js$/,
loader: 'babel-loader',
options: {
cacheDirectory: true,
presets: [ "@babel/preset-env" ].map(require.resolve),
plugins: [
//"transform-es3-property-literals", // #2452
//"transform-es3-member-expression-literals", // #2566
"@babel/plugin-transform-runtime" // #2566
],
sourceType: 'unambiguous'
}
},
{
test: /\.css$/,
use: [
'style-loader',
'css-loader'
]
},
]
}
};