forked from sandoche/Mobile-app-landingpage-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
webpack.dev.js
42 lines (41 loc) · 960 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
36
37
38
39
40
41
42
/* eslint-disable import/no-extraneous-dependencies */
const { merge: Merge } = require('webpack-merge');
const CommonConfig = require('./webpack.common.js');
const path = require('path');
const BrowserSyncPlugin = require('browser-sync-webpack-plugin');
const webpack = require('webpack');
module.exports = Merge(CommonConfig, {
output: {
filename: '[name].bundle.js',
path: path.resolve('assets'),
publicPath: '/assets/',
},
devtool: 'inline-source-map',
plugins: [
new BrowserSyncPlugin(
{
host: 'localhost',
port: 3000,
proxy: 'http://localhost:8080',
files: ['_site', '_src'],
},
{
reload: false,
},
),
new webpack.HotModuleReplacementPlugin(),
],
module: {},
devServer: {
static: {
directory: path.resolve('_site'),
},
hot: true,
client: {
overlay: {
errors: true,
warnings: false,
},
},
},
});