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

Test JSX linked editing #180769

Closed
3 tasks done
mjbvz opened this issue Apr 24, 2023 · 4 comments
Closed
3 tasks done

Test JSX linked editing #180769

mjbvz opened this issue Apr 24, 2023 · 4 comments

Comments

@mjbvz
Copy link
Collaborator

mjbvz commented Apr 24, 2023

Test for microsoft/TypeScript#51832

Complexity: 3

Create Issue


Summary

TS 5.1 enables linked editing for JSX tags. This means you can place your cursor on one tag and start editing to update the matching tag

Testing

  1. Enable linked editing: "editor.linkedEditing": true
  2. npm install typescript@next and switch your workspace to use TypeScript 5.1
  3. In a .tsx or .jsx file, try making linked edits to jsx tags

Some things to test:

  • Linked editing should stop once you type space or a non tag character
  • Linked editing should only effect the matching tags
  • Linked editing should not be activated when you are on an attribute
  • Linked editing should work when the cursor is on either the opening or closing tag
  • Pressing escape should exit linked editing mode
  • Linked editing should work for qualified names, like myNamespace.Component
@luabud
Copy link
Member

luabud commented Apr 26, 2023

Worked as expected :)

@ya2s
Copy link

ya2s commented Jun 10, 2023

@mjbvz @luabud
Works mostly well, but stops working when the tag name is empty

@justgage
Copy link

For some reason, it required me to restart VSCode (HTML-only files didn't), but after that, it works well. Thanks 🙂.

@ya2s
Copy link

ya2s commented Jun 14, 2023

I tried restarting but it doesn't work

@github-actions github-actions bot locked and limited conversation to collaborators Jun 17, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants