UNPKG

gulp-bird

Version:
44 lines (42 loc) 1 kB
var pkg = require('./package.json'); var webpack = require('webpack'); var ExtractTextPlugin = require('extract-text-webpack-plugin'); module.exports = { devtool: false, entry: { vconsole : './vconsole/vconsole.js' }, output: { path: './tools/vconsole', filename: '[name].min.js', library: 'vConsole', libraryTarget: 'umd', umdNameDefine: true }, module: { loaders: [ { test: /\.html$/, loader: 'html' }, { test: /\.js$/, loader: 'babel' }, { test: /\.scss$/, loader: 'style!css!sass' // loader: ExtractTextPlugin.extract('style-loader', 'css-loader!less-loader') // 将css独立打包 }, { test: /\.json$/, loader: 'json' } ] }, plugins: [ new webpack.optimize.UglifyJsPlugin({ compress: { warnings: false } }) ,new ExtractTextPlugin('[name].min.css') // 将css独立打包 ] };