wisemapping-frontend/packages/core-js/webpack.common.js
Paulo Gustavo Veiga 5ee7448d3c Format JS files.
2022-07-12 18:58:11 -07:00

36 lines
639 B
JavaScript

const path = require('path');
const { CleanWebpackPlugin } = require('clean-webpack-plugin');
module.exports = {
output: {
path: path.resolve(__dirname, 'dist'),
filename: 'core.js',
publicPath: '',
library: {
type: 'umd',
},
},
target: 'web',
optimization: {
usedExports: true,
},
module: {
rules: [
{
use: 'babel-loader',
test: /.js$/,
exclude: [/node_modules/],
},
],
},
resolve: {
extensions: ['.js'],
},
plugins: [
new CleanWebpackPlugin({
dangerouslyAllowCleanPatternsOutsideProject: true,
dry: false,
}),
],
};