-
Notifications
You must be signed in to change notification settings - Fork 20
/
Copy pathwebpack.config.development.js
55 lines (46 loc) · 1.15 KB
/
webpack.config.development.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
45
46
47
48
49
50
51
52
53
54
55
'use strict';
const webpack = require('webpack');
const path = require('path');
const WebpackNotifierPlugin = require('webpack-notifier');
const merge = require('webpack-merge');
const CommonsChunkPlugin = require('webpack/lib/optimize/CommonsChunkPlugin');
const webpackCommon = require('./webpack.config.common');
const VERSION = require('./package.json').version;
const ENV_VAR = {
'process.env': {
'VERSION': JSON.stringify(VERSION),
'NODE_ENV': JSON.stringify('development')
}
};
const config = merge(webpackCommon, {
entry: {
'availity-angular': './src/index.js',
'vendor': './docs/js/vendor',
'docs': './docs/js'
},
resolve: {
alias: {
demo: path.resolve( __dirname, './docs/js/module')
}
},
stats: {
assets: false,
colors: true,
hash: false,
version: true,
timings: true,
chunks: false,
chunkModules: false,
cached: true,
cachedAssets: true
},
plugins: [
new webpack.DefinePlugin(ENV_VAR),
new WebpackNotifierPlugin({excludeWarnings: true}),
new CommonsChunkPlugin({
name: ['vendor'],
minChunks: Infinity
})
]
});
module.exports = config;