forked from jellyfin/jellyfin-web
-
Notifications
You must be signed in to change notification settings - Fork 0
/
webpack.dev.js
35 lines (34 loc) · 949 Bytes
/
webpack.dev.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
const common = require('./webpack.common');
const { merge } = require('webpack-merge');
module.exports = merge(common, {
// In order for live reload to work we must use "web" as the target not "browserlist"
target: process.env.WEBPACK_SERVE ? 'web' : 'browserslist',
mode: 'development',
entry: './scripts/site.js',
devtool: 'source-map',
module: {
rules: [
{
test: /\.(js|jsx)$/,
exclude: /node_modules/,
enforce: 'pre',
use: ['source-map-loader']
},
{
test: /\.(ts|tsx)$/,
exclude: /node_modules/,
enforce: 'pre',
use: ['source-map-loader']
}
]
},
devServer: {
compress: true,
client: {
overlay: {
errors: true,
warnings: false
}
}
}
});