Skip to content

Should project references check for transitive references to do the declaration file include check #27200

@sheetalkamat

Description

@sheetalkamat

Issue created from #27195 (review)
Need to identify what needs to happen in this scenario:

Does this work for transitive projectReferenes? I'm asking because I struggled with that too.

// @filename: tsconfig.a.json
{"compilerOptions": {"composite"}, "files": ["a.ts"]}

// @filename: a.ts
export class A {}

// @filename: tsconfig.b.json
{"compilerOptions": {"composite"}, "files": ["b.ts"], "references": [{"path": "tsconfig.a.json"}]}

// @filename: b.ts
import {A} from './a';
export const b = new A();

// @filename: tsconfig.c.json
{"files": ["c.ts"], "references": [{"path": "tsconfig.b.json"}]}

// @filename: c.ts
import {b} from './b';
console.log(b);

Compiling tsconfig.c.json should resolve imports as b.d.ts and a.d.ts. I guess the current implementation resolves imports to b.d.ts and a.ts.

Metadata

Metadata

Assignees

Labels

FixedA PR has been merged for this issue

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions