babel-plugin-jsx/scripts/webpack.base.conf.js
renovate[bot] 367d21d7af
chore(deps): update all non-major dependencies (#611)
* chore(deps): update all non-major dependencies

* chore: remove the lockfile and reinstall to update trnasitive deps

The outdated `@types/babel__traverse` package is causing type errors

* fix: fix htmlTags type error

* fix: pin @types/node to 18.8.0 to work around https://github.com/johnsoncodehk/volar/issues/1985

* fix: pin @vue/test-utils temporarily to avoid snapshot differences

* test: update snapshot

As far as I see, all the snapshot differences are merely the newlines
after `import` statements

* test: add `attachTo: document.body` to make click event take effect

See https://github.com/vuejs/test-utils/issues/1470#issuecomment-1114752388

* fix: fix mjs processing for webpack 4

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Haoqun Jiang <haoqunjiang@gmail.com>
2022-10-15 10:33:17 +08:00

49 lines
954 B
JavaScript

const path = require('path');
const HtmlWebpackPlugin = require('html-webpack-plugin');
module.exports = {
mode: 'development',
devtool: false,
context: path.join(__dirname, '../packages/jsx-explorer'),
entry: './src/index.ts',
output: {
publicPath: './',
},
module: {
rules: [
{
test: /\.tsx?$/,
loader: 'ts-loader',
exclude: /node_modules/,
options: {
transpileOnly: true,
compilerOptions: { downlevelIteration: true },
},
},
{
test: /\.css$/,
use: [
'style-loader', 'css-loader',
],
},
{
test: /\.mjs$/,
include: /node_modules/,
type: 'javascript/auto'
}
],
},
plugins: [
new HtmlWebpackPlugin({
template: 'index.html',
filename: 'index.html',
}),
],
resolve: {
extensions: ['.ts', '.js', '.mjs'],
},
node: {
fs: 'empty',
},
};