UNPKG

vue-accordion

Version:

Simple accordion menu component for Vue.js

43 lines (41 loc) 765 B
var webpack = require('webpack'); var path = require('path'); module.exports = { entry: './src/index.js', output: { path: path.resolve(__dirname, './dist'), filename: 'vue-accordion.js', libraryTarget: 'umd' }, module: { rules: [ { test: /\.vue$/, loader: 'vue-loader' }, { test: /\.js$/, loader: 'babel-loader', exclude: /node_modules/ } ] } }; if (process.env.NODE_ENV === 'production') { module.exports.plugins = (module.exports.plugins || []).concat([ new webpack.DefinePlugin({ 'process.env': { NODE_ENV: '"production"' } }), new webpack.optimize.UglifyJsPlugin({ sourceMap: true, compress: { warnings: false } }), new webpack.LoaderOptionsPlugin({ minimize: true }) ]) }