From 2580111b95a2cce5cab244c7438b736dc69640a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=B2=81=E6=A0=91=E4=BA=BA?= Date: Wed, 11 Oct 2023 19:54:18 +0100 Subject: [PATCH] build: fix build issue with terser --- package.json | 1 + patches/@rollup__plugin-terser@0.4.3.patch | 22 ++++++++++++++++++++++ pnpm-lock.yaml | 8 ++++++-- 3 files changed, 29 insertions(+), 2 deletions(-) create mode 100644 patches/@rollup__plugin-terser@0.4.3.patch diff --git a/package.json b/package.json index a3be058..afb0c31 100644 --- a/package.json +++ b/package.json @@ -78,6 +78,7 @@ }, "pnpm": { "patchedDependencies": { + "@rollup/plugin-terser@0.4.3": "patches/@rollup__plugin-terser@0.4.3.patch", "sql.js@1.8.0": "patches/sql.js@1.8.0.patch" }, "overrides": { diff --git a/patches/@rollup__plugin-terser@0.4.3.patch b/patches/@rollup__plugin-terser@0.4.3.patch new file mode 100644 index 0000000..0efad14 --- /dev/null +++ b/patches/@rollup__plugin-terser@0.4.3.patch @@ -0,0 +1,22 @@ +diff --git a/dist/cjs/index.js b/dist/cjs/index.js +index 23639c70ccd5ebbc4a12c1ba277e5ac81cf30513..aba3318977523785d02f3b8aa6e667a1aa46bf5d 100644 +--- a/dist/cjs/index.js ++++ b/dist/cjs/index.js +@@ -227,5 +227,5 @@ function terser(input = {}) { + runWorker(); + + exports.default = terser; +-module.exports = Object.assign(exports.default, exports); ++module.exports = Object.assign(exports.default, exports, { terser }); + //# sourceMappingURL=index.js.map +diff --git a/dist/es/index.js b/dist/es/index.js +index 7296e677e6b2b38df9522b196fee24feec996793..4ca9052dd439ed22ff92cc72a79824b85e229678 100644 +--- a/dist/es/index.js ++++ b/dist/es/index.js +@@ -222,5 +222,5 @@ function terser(input = {}) { + + runWorker(); + +-export { terser as default }; ++export { terser as default, terser }; + //# sourceMappingURL=index.js.map diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index ddfff4e..bfc47b4 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -9,6 +9,9 @@ overrides: sourcemap-codec: npm:@jridgewell/sourcemap-codec@1.4.15 patchedDependencies: + '@rollup/plugin-terser@0.4.3': + hash: ztv2kzvfqbmz5mcxzgjd7ae7qy + path: patches/@rollup__plugin-terser@0.4.3.patch sql.js@1.8.0: hash: vzg36y5uoz6bb2m2utejemkdhy path: patches/sql.js@1.8.0.patch @@ -3003,7 +3006,7 @@ packages: rollup: 2.79.1 dev: true - /@rollup/plugin-terser@0.4.3(rollup@2.79.1): + /@rollup/plugin-terser@0.4.3(patch_hash=ztv2kzvfqbmz5mcxzgjd7ae7qy)(rollup@2.79.1): resolution: {integrity: sha512-EF0oejTMtkyhrkwCdg0HJ0IpkcaVg1MMSf2olHb2Jp+1mnLM04OhjpJWGma4HobiDTF0WCyViWuvadyE9ch2XA==} engines: {node: '>=14.0.0'} peerDependencies: @@ -3017,6 +3020,7 @@ packages: smob: 1.4.1 terser: 5.21.0 dev: true + patched: true /@rollup/plugin-virtual@3.0.2(rollup@2.79.1): resolution: {integrity: sha512-10monEYsBp3scM4/ND4LNH5Rxvh3e/cVeL3jWTgZ2SrQ+BmUoQcopVQvnaMcOnykb1VkxUFuDAN+0FnpTFRy2A==} @@ -7226,7 +7230,7 @@ packages: lodash: 4.17.21 pretty-bytes: 5.6.0 rollup: 2.79.1 - rollup-plugin-terser: /@rollup/plugin-terser@0.4.3(rollup@2.79.1) + rollup-plugin-terser: /@rollup/plugin-terser@0.4.3(patch_hash=ztv2kzvfqbmz5mcxzgjd7ae7qy)(rollup@2.79.1) source-map: 0.8.0-beta.0 stringify-object: 3.3.0 strip-comments: 2.0.1