-
Notifications
You must be signed in to change notification settings - Fork 5
/
webpack.config.js
32 lines (31 loc) · 791 Bytes
/
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
const path = require('path');
const webpack = require('webpack');
const metadata = require('./package.json')
module.exports = {
mode: 'production',
entry: './index.js',
output: {
path: path.resolve(__dirname, 'dist'),
filename: 'lps-' + metadata.version + '.bundle.js'
},
resolveLoader: {
modules: [
'node_modules',
path.resolve(__dirname, 'loaders')
]
},
module: {
rules: [
{ test: /\.lps/, use: 'lps-min-loader' }
]
},
plugins: [
new webpack.IgnorePlugin(/engine\/modules\/(p2p|fs)/),
new webpack.IgnorePlugin(/engine\/processors\/consult/),
new webpack.BannerPlugin('lps.js ' + metadata.version + ' (browser). BSD-3-Clause. https://github.com/mauris/lps.js')
],
node: {
fs: 'empty',
net: 'empty'
}
};