Fix: Resolver error '../pkg' en build Docker
All checks were successful
build-and-deploy / build-and-deploy (push) Successful in 1m3s

This commit is contained in:
2025-12-20 11:21:51 -06:00
parent e1b0bdf823
commit 8b588d9381

View File

@@ -33,6 +33,11 @@ export function disableImportProtection(): Plugin {
return emptyModulePath return emptyModulePath
} }
// Stub problematic relative pkg imports (WASM/native packages)
if (id === '../pkg' || id.includes('../pkg?')) {
return emptyModulePath
}
// Stub Node.js built-in modules for client bundle // Stub Node.js built-in modules for client bundle
const nodeModules = ['fs', 'path', 'url', 'fs/promises'] const nodeModules = ['fs', 'path', 'url', 'fs/promises']
const nodePrefix = ['node:url', 'node:module', 'node:fs', 'node:path'] const nodePrefix = ['node:url', 'node:module', 'node:fs', 'node:path']