which extension just modified on my files?

2019-01-20 19:31发布

问题:

Is there any ways to know which extension has modified my files.

I have a problem where once I move a file to another folder all my paths are being rewritten.from like import from '../component/hello.js' to 'import from 'component/hello.js'`

It is really annoying since it would do it for all the files in my app.

thank you

回答1:

I am currently unable to test this but see this setting:

// Enable/disable automatic updating of import paths when you rename or move a file in VS Code. Possible values are: 'prompt' on each rename, 'always' update paths automatically, and 'never' rename paths and don't prompt me. Requires using TypeScript 2.9 or newer in the workspace.

  "javascript.updateImportsOnFileMove.enabled": "prompt",

"prompt" is the default so you should be seeing that if this is the cause of the updating of your import paths. In any case, try "never".