-
Notifications
You must be signed in to change notification settings - Fork 0
/
webpack.dev.config.js
43 lines (42 loc) · 1.02 KB
/
webpack.dev.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
const path = require('path')
const HTMLWebpackPlugin = require('html-webpack-plugin')
module.exports = {
entry: './src/index.js',
mode: 'development',
devServer: {
historyApiFallback: true
},
output: {
filename: 'index_bundle.js'
},
plugins: [
new HTMLWebpackPlugin({
// Use this template to get basic responsive meta tags
template: 'functions/index.ejs',
templateParameters: {
renderedHtml: '', // Disabled for dev mode, to test use `npm run serve`
bundlePath: 'http://localhost:3000/index_bundle.js' // Disabled for dev mode, to test use `npm run serve`
},
inject: false
})
],
resolve: {
modules: [path.join(__dirname, 'src'), 'node_modules'],
extensions: ['.js', '.elm']
},
module: {
rules: [
{
test: /\.elm$/,
exclude: [/elm-stuff/, /node_modules/],
use: {
loader: 'elm-webpack-loader',
options: {
verbose: true,
debug: true
}
}
}
]
}
}