@@ -1,5 +1,6 @@
|
||||
/js/tests/*
|
||||
/js/vendor/*
|
||||
/js/legacy/*
|
||||
/js/node_modules/*
|
||||
/js/public/*
|
||||
/karma.conf.js
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
const path = require('path');
|
||||
const webpack = require('webpack');
|
||||
const MiniCssExtractPlugin = require("mini-css-extract-plugin");
|
||||
const MiniCssExtractPlugin = require('mini-css-extract-plugin');
|
||||
|
||||
module.exports = {
|
||||
node: {
|
||||
@@ -27,7 +27,7 @@ module.exports = {
|
||||
test: /\.css$/,
|
||||
use: [
|
||||
MiniCssExtractPlugin.loader,
|
||||
"css-loader"
|
||||
'css-loader'
|
||||
]
|
||||
}
|
||||
]
|
||||
@@ -38,25 +38,26 @@ module.exports = {
|
||||
/* separate vendor chunk for node_modules and legacy scripts */
|
||||
commons: {
|
||||
test: /[\\/]node_modules[\\/]/,
|
||||
name: "vendor",
|
||||
chunks: "all"
|
||||
name: 'vendor',
|
||||
chunks: 'all'
|
||||
},
|
||||
legacy: {
|
||||
test: /[\\/]legacy[\\/]/,
|
||||
name: "vendor",
|
||||
chunks: "all"
|
||||
name: 'vendor',
|
||||
chunks: 'all'
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
/* use external jQuery from server */
|
||||
externals: {
|
||||
"jquery": "jQuery"
|
||||
'jquery': 'jQuery'
|
||||
},
|
||||
plugins: [
|
||||
new MiniCssExtractPlugin('css/[name].css'),
|
||||
new MiniCssExtractPlugin('[name].css'),
|
||||
new webpack.ProvidePlugin({
|
||||
$: "jquery",
|
||||
jQuery: "jquery"
|
||||
$: 'jquery',
|
||||
jQuery: 'jquery'
|
||||
})
|
||||
]
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user