2015-07-21 12:02:15 +08:00
|
|
|
// webpack.config.min.js
|
|
|
|
// release min dist files
|
|
|
|
var pkg = require('./package');
|
|
|
|
var webpack = require("webpack");
|
|
|
|
var ExtractTextPlugin = require("extract-text-webpack-plugin");
|
|
|
|
var config = require("./webpack.config.js");
|
|
|
|
|
|
|
|
config.plugins = [
|
|
|
|
new ExtractTextPlugin('[name].min.css'),
|
2015-07-22 15:05:56 +08:00
|
|
|
new webpack.optimize.UglifyJsPlugin({
|
|
|
|
output: {
|
|
|
|
ascii_only: true
|
|
|
|
}
|
|
|
|
})
|
2015-07-21 12:02:15 +08:00
|
|
|
];
|
|
|
|
config.output.filename = config.output.filename.replace(/\.js$/, ".min.js");
|
|
|
|
delete config.entry.demo;
|
|
|
|
delete config.entry[pkg.name];
|
|
|
|
|
|
|
|
module.exports = config;
|