diff --git a/src/builder/rollup.ts b/src/builder/rollup.ts index fd4185d9..4a1dd28d 100644 --- a/src/builder/rollup.ts +++ b/src/builder/rollup.ts @@ -260,7 +260,7 @@ export function getRollupOptions(ctx: BuildContext): RollupOptions { external(id) { const pkg = getpkg(id); - const isExplicitExternal = arrayIncludes(ctx.options.externals, pkg); + const isExplicitExternal = arrayIncludes(ctx.options.externals, pkg) || arrayIncludes(ctx.options.externals, id); if (isExplicitExternal) { return true; }