2025-07-16 22:29:28 +08:00
|
|
|
"use strict";
|
|
|
|
|
2023-05-24 13:44:06 +08:00
|
|
|
const TerserPlugin = require("terser-webpack-plugin");
|
2025-07-03 17:06:45 +08:00
|
|
|
const webpack = require("../../../../");
|
2023-05-24 13:44:06 +08:00
|
|
|
|
2023-05-24 13:43:18 +08:00
|
|
|
/** @type {import("../../../../types").Configuration} */
|
|
|
|
module.exports = {
|
|
|
|
node: {
|
|
|
|
__dirname: false,
|
|
|
|
__filename: false
|
|
|
|
},
|
|
|
|
entry: {
|
|
|
|
bundle0: ["./index.js"],
|
|
|
|
"some-test": ["./test.js"]
|
|
|
|
},
|
|
|
|
output: {
|
|
|
|
filename: "[name].js"
|
|
|
|
},
|
|
|
|
optimization: {
|
|
|
|
minimizer: [new TerserPlugin()]
|
|
|
|
},
|
|
|
|
plugins: [
|
|
|
|
new webpack.SourceMapDevToolPlugin({
|
|
|
|
filename: "sourcemaps/[file].map",
|
2025-07-08 22:46:17 +08:00
|
|
|
append: () => "\n//# sourceMappingURL=http://localhost:50505/[file].map"
|
2023-05-24 13:43:18 +08:00
|
|
|
})
|
|
|
|
]
|
|
|
|
};
|