fix(build): externalize resvg when bundling wechat-mp runtime

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
john
2026-07-04 12:54:27 +08:00
parent 6bc5d128d2
commit f36e8b9292
+8
View File
@@ -15,11 +15,19 @@ const outfile = outputArg
: path.join(runtimeRoot, 'wechat-mp.bundle.mjs'); : path.join(runtimeRoot, 'wechat-mp.bundle.mjs');
const externalPackages = [ const externalPackages = [
'@img/sharp-darwin-arm64',
'@img/sharp-libvips-darwin-arm64',
'@node-rs/argon2',
'@resvg/resvg-js',
'undici', 'undici',
'mysql2', 'mysql2',
'mysql2/promise', 'mysql2/promise',
'sharp', 'sharp',
'fsevents', 'fsevents',
'playwright',
'playwright-core',
'chromium-bidi',
'chromium-bidi/*',
]; ];
function run(command, args) { function run(command, args) {