33 lines
683 B
JavaScript
Raw Normal View History

2021-10-02 19:52:56 -07:00
const path = require('path');
const { CleanWebpackPlugin } = require('clean-webpack-plugin');
2021-07-16 11:41:58 -03:00
module.exports = {
2021-07-16 11:41:58 -03:00
output: {
path: path.resolve(__dirname, 'dist'),
2021-07-16 11:41:58 -03:00
filename: 'core.js',
publicPath: '',
library: {
type: 'umd',
2021-12-14 15:08:54 +00:00
}
2021-07-16 11:41:58 -03:00
},
2021-10-02 20:29:24 -07:00
target: 'web',
2021-12-19 18:46:47 -08:00
optimization: {
usedExports: true,
},
2021-07-16 11:41:58 -03:00
module: {
rules: [
{
use: 'babel-loader',
2021-10-02 19:52:56 -07:00
test: /.js$/,
exclude: [
/node_modules/,
]
},
2021-07-16 11:41:58 -03:00
],
},
resolve: {
2021-10-02 19:52:56 -07:00
extensions: ['.js'],
2021-07-16 11:41:58 -03:00
},
plugins: [new CleanWebpackPlugin()],
};