|
@@ -9,7 +9,6 @@ module.exports = {
|
|
|
entry: {
|
|
|
index: path.resolve(__dirname, 'src', 'index.js'),
|
|
|
page: path.resolve(__dirname, 'src', 'page.js'),
|
|
|
- scoreSheet: path.resolve(__dirname, 'src', 'scoreSheet.js'),
|
|
|
information: path.resolve(__dirname, 'src/js', 'information.js'),
|
|
|
drugInfo: path.resolve(__dirname, 'src/js', 'drugInfo.js'),
|
|
|
disclaimer: path.resolve(__dirname, 'src/js', 'disclaimer.js'),
|
|
@@ -53,19 +52,6 @@ module.exports = {
|
|
|
collapseWhitespace: true //删除空白符与换行符
|
|
|
}
|
|
|
}),
|
|
|
- new HtmlWebpackPlugin({
|
|
|
- title: 'scoreSheet',
|
|
|
- template: path.resolve(__dirname, 'src/html', 'scoreSheet.html'),
|
|
|
- filename: 'scoreSheet.html',
|
|
|
- chunks: ['scoreSheet', 'vendor','common'],
|
|
|
- inject: true,
|
|
|
- hash: true, //防止缓存
|
|
|
- minify: {
|
|
|
- removeAttributeQuotes: true, //压缩 去掉引号
|
|
|
- removeComments: true, //移除HTML中的注释
|
|
|
- collapseWhitespace: true //删除空白符与换行符
|
|
|
- }
|
|
|
- }),
|
|
|
new HtmlWebpackPlugin({
|
|
|
title: 'information',
|
|
|
template: path.resolve(__dirname, 'src/html', 'information.html'),
|
|
@@ -136,7 +122,7 @@ module.exports = {
|
|
|
minChunks: 2,
|
|
|
maxInitialRequests: 5, // The default limit is too small to showcase the effect
|
|
|
minSize: 0, // This is example is too small to create commons chunks
|
|
|
- reuseExistingChunk: true // 可设置是否重用该chunk(查看源码没有发现默认值)
|
|
|
+ reuseExistingChunk: true // 可设置是否重用该chunk
|
|
|
}
|
|
|
}
|
|
|
}
|