Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TS rename causes many type definitions files to open for NPM packages #53340

Closed
kyle-mccarthy opened this issue Jun 29, 2018 · 5 comments
Closed
Assignees
Labels
info-needed Issue requires more information from poster typescript Typescript support issues

Comments

@kyle-mccarthy
Copy link

kyle-mccarthy commented Jun 29, 2018

With "typescript.updateImportsOnFileMove.enabled" setting set to "always", after renaming a TS file, many TS definitions files from NPM packages will open. When going to close the .d.ts files, VS code will think a change was made and prompt to save the package file.

  • VSCode Version: Version 1.24.1 (1.24.1)
  • OS Version: MacOS High Sierra 10.13.5 (17F77)

Steps to Reproduce:

  1. Open TS file in project
  2. Rename open file
  3. Many definitions files from NPM packages open after change

Does this issue occur when all extensions are disabled?: Yes

bu0toawr8z

It seemed similar to #53186 but the trigger and result are different.

@vscodebot
Copy link

vscodebot bot commented Jun 29, 2018

(Experimental duplicate detection)
Thanks for submitting this issue. Please also check if it is already covered by an existing one, like:

@vscodebot vscodebot bot added the typescript Typescript support issues label Jun 29, 2018
@mjbvz
Copy link
Collaborator

mjbvz commented Jun 29, 2018

Does this reproduce in the latest VS Code build with all extensions disabled? I recently made a fix for this but it is only in insiders

@mjbvz mjbvz added the info-needed Issue requires more information from poster label Jun 29, 2018
@kyle-mccarthy
Copy link
Author

@mjbvz I just tried it out and while it didn't open any type def files, it opened several unrelated project files.

b96cdnp6c5

@mjbvz
Copy link
Collaborator

mjbvz commented Jul 2, 2018

Please try upgrading your workspace to use typescript@next by following these instructions. Do you still see this issue after upgrading?

@mjbvz
Copy link
Collaborator

mjbvz commented Jul 6, 2018

Closing as duplicate of microsoft/TypeScript#24914. The next VS Code insiders will include this fix. Let me know if you still see this issue when using TypeScript 3.0+ in your workspace

@mjbvz mjbvz closed this as completed Jul 6, 2018
@vscodebot vscodebot bot locked and limited conversation to collaborators Aug 20, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
info-needed Issue requires more information from poster typescript Typescript support issues
Projects
None yet
Development

No branches or pull requests

2 participants