| 12345678910111213141516171819202122232425262728293031323334353637383940 |
- /*
- * @Author: xiaolin
- * @Date: 2022-10-14 10:31:52
- * @LastEditors: xiaolin
- * @LastEditTime: 2022-10-17 11:45:23
- * @Description: file content
- * @FilePath: \image.platform.com\xyxJsSdkV2\webpack.config.js
- */
- const TerserPlugin = require("terser-webpack-plugin");
- const path = require("path");
- const pkg = require("./package.json");
- module.exports = {
- entry: {
- dyMiniGameSdk: "./index.js",
- },
- experiments: {
- outputModule: true,
- },
- output: {
- filename: `[name].${pkg.version}.js`,
- path: path.resolve(__dirname, "dist"),
- library: {
- type: "module",
- },
- },
- optimization: {
- minimize: true,
- minimizer: [
- new TerserPlugin({
- terserOptions: {
- format: {
- comments: false,
- },
- },
- extractComments: false,
- }),
- ],
- },
- // devtool: 'source-map',
- };
|