Microsoft/vscode

Deleting JSX tag name and then typing a different tag name doesn't update closing tag

オープン

#247,235 opened on 2025/04/23

 (9 件のコメント) (0 件のリアクション) (1 人の担当者)TypeScript (39,847 件のフォーク)batch import
bugeditor-synced-regionenhancementhelp wanted

Repository metrics

Stars
 (184,936 個のスター)
PR merge metrics
 (PR metrics pending)

説明

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

  • VSCode Version: 1.99.3 (Universal)
  • OS Version: Darwin x64 24.3.0

Steps to Reproduce:

  1. Go to the end of the name of an opening JSX/TSX tag
  2. Backspace to delete the name
  3. Type the new name
  4. The closing tag should also be updated but it remains blank

This is really annoying and I'm confused why I can't find any other issue reports about it. Maybe a lot of people select the tag name before typing over it, but that workaround is no good for Vim users (for whom it's most efficient to cw at the start of the tag, which deletes it and goes into insert mode, and then type the new tag name).

VSCode could make this work even though the syntax temporarily becomes invalid when the tag name has been deleted; all it would take is remembering the opening/closing tag name positions when all characters in the tag name get deleted, and keeping that in memory until the next document edit.

https://github.com/user-attachments/assets/35c21b5f-a64f-4d56-8933-dfc5f3f65f88

コントリビューターガイド