js-waku/packages/browser-tests/webpack.config.js
Arseniy Klempner e901f24c9d
feat: consolidate browser testing code into a single package
feat: simplify browser sim image to light push flow
2025-09-05 10:08:16 -07:00

36 lines
708 B
JavaScript

import path from "path";
import { fileURLToPath } from "url";
import NodePolyfillPlugin from "node-polyfill-webpack-plugin";
const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
export default {
mode: "production",
entry: "./web/index.js",
output: {
path: path.resolve(__dirname, "web"),
filename: "bundle.js",
clean: true
},
module: {
rules: [
{
test: /\.ts$/,
use: "babel-loader",
exclude: /node_modules/
}
]
},
resolve: {
extensions: [".ts", ".js"],
fallback: {
fs: false,
net: false,
tls: false
}
},
plugins: [new NodePolyfillPlugin()],
target: "web"
};