From b4e25cdba0708b1b2a4aacbd499ec3ff21871c8c Mon Sep 17 00:00:00 2001 From: Malte Ubl Date: Sat, 17 Oct 2026 21:01:15 -0700 Subject: [PATCH] Leave an @types twin with no runtime package to the declaration bar in transitive selection Co-Authored-By: Claude Opus 5.5 --- packages/compiler/src/frontend/pipeline.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/compiler/src/frontend/pipeline.ts b/packages/compiler/src/frontend/pipeline.ts index 20df75c9b..c769ed99e 100644 --- a/packages/compiler/src/frontend/pipeline.ts +++ b/packages/compiler/src/frontend/pipeline.ts @@ -214,7 +214,9 @@ function detectAutoPackages( continue; } if (judged?.has(npm.packageName)) continue; - if (viaTransitive) { + // An @types twin with no runtime package installed has nothing to + // compile (Node cannot load it either). + if (viaTransitive && !npm.packageName.startsWith("@types/")) { judged!.add(npm.packageName); sites!.set(npm.packageName, loc); transitive.add(npm.packageName);