2017-03-08 18:41:05 +00:00
|
|
|
var baseConfig = require('./webpackBaseConfig')
|
2018-09-02 08:57:59 +00:00
|
|
|
const MiniCssExtractPlugin = require('mini-css-extract-plugin')
|
2017-03-08 18:41:05 +00:00
|
|
|
var path = require('path')
|
2016-10-07 15:05:23 +00:00
|
|
|
|
2016-11-02 10:01:26 +00:00
|
|
|
module.exports = [Object.assign({}, baseConfig, {
|
2017-03-08 18:41:05 +00:00
|
|
|
plugins: baseConfig.plugins.concat([
|
2018-09-02 08:57:59 +00:00
|
|
|
new MiniCssExtractPlugin({
|
|
|
|
filename: '[name].css',
|
|
|
|
chunkFilename: '[id].css'
|
|
|
|
})
|
|
|
|
|
2017-04-11 08:39:47 +00:00
|
|
|
]),
|
|
|
|
devtool: 'source-map'
|
2016-11-02 10:01:26 +00:00
|
|
|
}), {
|
2017-04-11 08:39:47 +00:00
|
|
|
devtool: 'source-map',
|
2017-03-08 18:41:05 +00:00
|
|
|
entry: {
|
|
|
|
htmlExport: path.join(__dirname, 'public/js/htmlExport.js')
|
|
|
|
},
|
|
|
|
module: {
|
2018-09-02 08:57:59 +00:00
|
|
|
rules: [{
|
2017-03-08 18:41:05 +00:00
|
|
|
test: /\.css$/,
|
2018-09-02 08:57:59 +00:00
|
|
|
use: ['style-loader', 'css-loader']
|
2017-03-08 18:41:05 +00:00
|
|
|
}, {
|
|
|
|
test: /\.scss$/,
|
2018-09-02 08:57:59 +00:00
|
|
|
use: ['style-loader', 'sass-loader']
|
2017-03-08 18:41:05 +00:00
|
|
|
}, {
|
|
|
|
test: /\.less$/,
|
2018-09-02 08:57:59 +00:00
|
|
|
use: ['style-loader', 'less-loader']
|
2017-03-08 18:41:05 +00:00
|
|
|
}]
|
|
|
|
},
|
|
|
|
output: {
|
|
|
|
path: path.join(__dirname, 'public/build'),
|
|
|
|
publicPath: '/build/',
|
|
|
|
filename: '[name].js'
|
|
|
|
},
|
|
|
|
plugins: [
|
2018-09-02 08:57:59 +00:00
|
|
|
new MiniCssExtractPlugin({
|
|
|
|
filename: 'html.min.css'
|
|
|
|
})
|
2017-03-08 18:41:05 +00:00
|
|
|
]
|
|
|
|
}]
|