-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathwebpack.config.js
44 lines (43 loc) · 1.16 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
const CopyWebpackPlugin = require('copy-webpack-plugin')
const path = require('path')
const PATHS = {
src: path.join(__dirname, 'web'),
dist: path.join(__dirname, 'web/dist'),
}
module.exports = {
mode: 'development',
entry: {
app: PATHS.src + '/js/app.js',
},
output: {
path: PATHS.dist,
filename: 'js/[name].js',
},
plugins: [
new CopyWebpackPlugin({
patterns: [
{
from: 'node_modules/bootstrap/dist/css/bootstrap.css',
to: 'css',
},
{
from:
'node_modules/bootstrap/dist/js/bootstrap.bundle.min.js',
to: 'js',
},
{
from: 'node_modules/jquery/dist/jquery.min.js',
to: 'js',
},
{
from: 'node_modules/moment/moment.js',
to: 'js',
},
{
from: 'node_modules/mithril/mithril.min.js',
to: 'js',
},
],
}),
],
}