Concat jquery and materialize in separated bundle.
This commit is contained in:
parent
a20e481f08
commit
13d79ae567
@ -43,6 +43,7 @@
|
||||
"typescript": "^2.4.2",
|
||||
"url-loader": "^0.6.2",
|
||||
"webpack": "^3.8.1",
|
||||
"webpack-concat-plugin": "^1.4.1",
|
||||
"webpack-dev-server": "^2.9.3"
|
||||
},
|
||||
"dependencies": {
|
||||
|
@ -2,6 +2,7 @@
|
||||
const path = require('path');
|
||||
const HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||
const webpack = require('webpack');
|
||||
const ConcatPlugin = require('webpack-concat-plugin');
|
||||
|
||||
module.exports = {
|
||||
context: path.resolve(__dirname, 'src'),
|
||||
@ -114,6 +115,17 @@ module.exports = {
|
||||
}]
|
||||
},
|
||||
plugins: [
|
||||
new ConcatPlugin({
|
||||
uglify: false,
|
||||
sourceMap: true,
|
||||
useHash: false,
|
||||
name: "vendor",
|
||||
fileName: "[name].bundle.js",
|
||||
filesToConcat: [
|
||||
"node_modules/jquery/dist/jquery.min.js",
|
||||
"node_modules/materialize-css/dist/js/materialize.min.js"
|
||||
]
|
||||
}),
|
||||
new webpack.ProvidePlugin({
|
||||
Materialize: "materialize-css",
|
||||
$: "jquery",
|
||||
|
Loading…
Reference in New Issue
Block a user