Skip to content

Visual Studio 2017 is compiling JS file without associated TS file #14827

@styfle

Description

@styfle

TypeScript Version: 2.1.5

Code
Get master branch from here:
https://github.com/styfle/TypeScriptReproBug

Expected behavior:
Do not compile .js files if there is no matching .ts file.

Actual behavior:
The .js files are modified and a .js.map file is generated.

More Info

I opened an existing 2015 project in VS 2017, edited a .d.ts file, saved, and VS started compiling a lot of files....files that do not have a .ts associated with them 😨

image

Then I looked at git changes in Team Explorer tab and I can see that a bunch of .js files were modified and a bunch of .js.map files were added.

image

@billti Please review the code. Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in TypeScript

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions