wisemapping-frontend/packages/web2d/webpack.common.js
Paulo Gustavo Veiga ce03021308 Revert "Move lint"
This reverts commit cc8dc0c9bdbfe73bd66fed325aa7ba13efd1d3e1.
2021-10-04 16:22:33 -07:00

31 lines
748 B
JavaScript

const path = require('path');
const { CleanWebpackPlugin } = require('clean-webpack-plugin');
/** @type {import('webpack').Configuration} */
module.exports = {
entry: './lib/web2d.js',
output: {
path: path.resolve(__dirname, 'dist'),
filename: '[name].js',
publicPath: '',
},
module: {
rules: [
{
use: 'babel-loader',
test: /.(js|jsx)$/,
exclude: /node_modules/,
},
{
type: 'asset',
test: /\.(png|svg|jpg|jpeg|gif)$/i,
},
],
},
target: 'web',
resolve: {
extensions: ['.js', '.jsx', '.json'],
},
plugins: [new CleanWebpackPlugin()],
};