@axetroy/react-download
Version:
[](https://greenkeeper.io/)
35 lines (33 loc) • 752 B
JavaScript
const path = require('path');
const webpack = require('webpack');
const CopyWebpackPlugin = require('copy-webpack-plugin');
module.exports = {
entry: path.join(__dirname, 'example', 'src', 'index.jsx'),
output: {
filename: 'bundle.js',
path: path.join(__dirname, 'docs')
},
module: {
loaders: [
{
test: /\.jsx$/,
loader: 'babel-loader',
include: [path.join(__dirname, 'example')]
}
]
},
plugins: [
new CopyWebpackPlugin([
{
from: path.join(__dirname, 'example', 'index.html'),
to: path.join(__dirname, 'docs')
}
]),
new webpack.optimize.UglifyJsPlugin({
compress: {
warnings: false,
drop_console: false
}
})
]
};