diff --git a/package.json b/package.json index 829ee5d..ac6bbcf 100644 --- a/package.json +++ b/package.json @@ -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": { diff --git a/webpack.config.js b/webpack.config.js index 90e281f..53e6061 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -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",