mirror of
https://github.com/requarks/wiki.git
synced 2025-02-25 18:55:30 -06:00
23 lines
541 B
JavaScript
23 lines
541 B
JavaScript
const webpack = require('webpack')
|
|
const merge = require('webpack-merge')
|
|
|
|
const CleanWebpackPlugin = require('clean-webpack-plugin')
|
|
const UglifyJSPlugin = require('uglifyjs-webpack-plugin')
|
|
|
|
const common = require('./webpack.common.js')
|
|
|
|
console.info(process.cwd())
|
|
|
|
module.exports = merge(common, {
|
|
module: {
|
|
rules: []
|
|
},
|
|
plugins: [
|
|
new CleanWebpackPlugin(['assets'], { root: process.cwd() }),
|
|
new UglifyJSPlugin(),
|
|
new webpack.DefinePlugin({
|
|
'process.env.NODE_ENV': JSON.stringify('production')
|
|
})
|
|
]
|
|
})
|