22 lines
446 B
JavaScript
22 lines
446 B
JavaScript
const CopyWebpackPlugin = require('copy-webpack-plugin');
|
|
const config = require('./config');
|
|
|
|
module.exports = {
|
|
mode: config.debug ? 'development' : 'production',
|
|
entry: `${__dirname}/src/index.js`,
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.js$/,
|
|
exclude: /node_modules/,
|
|
loader: 'babel-loader',
|
|
},
|
|
],
|
|
},
|
|
output: {
|
|
filename: 'index.js',
|
|
path: `${__dirname}/public`,
|
|
publicPath: '/',
|
|
}
|
|
};
|