Skip to content

compileOnSave emits referenced compile output #35226

Closed
@HolgerJeromin

Description

@HolgerJeromin

TypeScript Version: 3.7.2 (worked with 3.6.2)

Search Terms: project references

Code
ts_include_onsave.zip
is a solution archive for visual studio 2019.

Repro step
Compile the solution and look at the output file Controls\SiblingClass\Source.js.
compileOnSave on the file Controls\SiblingClass\Source.ts

Expected behavior:
"Solution build" and "compile on save" should generate the same js files.
Only logic from Hmi.Sibling should be emitted in both compile ways.

Actual behavior:
compileOnSave emits additional js code from Hmi.buttonClass which is referenced via project references.

I suspect #32028 is the source of the problem. (cc @sheetalkamat ) even if this was mentioned in the PR:

compile on save -> do not emit files that are sources of project reference redirects

Metadata

Metadata

Assignees

Labels

BugA bug in TypeScriptFix AvailableA PR has been opened for this issue

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions