Relative dependencies for files do not update properly when moving multiple files at once between folders.

未关闭
#45,326 5 条评论 2 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
40/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
停滞
领域
tooling

调研方向

首先,在 VS Code 中使用一个包含三个 JavaScript 文件的 Node 项目复现该问题,这些文件通过 require() 或 import 相互引用,然后将其中两个文件一起移动。报告中没有指定源文件或测试,因此请跟踪多文件移动处理以及相对导入的更新。完成的标准是移动后每个受影响的导入都正确,包括移动文件之间的引用。

由索引模型根据 Issue 内容生成。

描述

Needs Investigation

Problem: Relative dependencies for files do not update properly when moving multiple files at once between folders.

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

VSCode Information:
Version: 1.58.2 (user setup)
Commit: c3f126316369cd610563c75b1b1725e0679adfb3
Date: 2021-07-14T22:10:15.214Z
Electron: 12.0.13
Chrome: 89.0.4389.128
Node.js: 14.16.0
V8: 8.9.255.25-electron.0
OS: Windows_NT x64 10.0.19042

Steps to Reproduce (JavaScript):

  1. Make new Node project with npm init and open the folder in VSCode.
  2. Create three JavaScript files which all reference each other using require() or import.
  3. Create a folder in the workspace.
  4. Move two of the files into the folder (have them both selected and move them together).

The imports of the moved files will now be left unchanged and hence incorrect (except one, which is why moving a single file is bug-free).

主要语言
Go
星标
111k
派生
14.4k
平均合并
1 天 19 小时
30 天内合并 PR
117

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

microsoft/TypeScript 的其他 Issue

查看 microsoft/TypeScript 的全部 Issue

相似的 Issue

更多 Go Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。