microsoft / microsoft/TypeScript
Auto-delete closing tag when opening tag becomes self-closed
Nessuno ha ancora preso questa issue.
- Lingua principale
- Go
- Stelle
- 111k
- Fork
- 14.3k
- Merge medio
- 2g 4h
- PR unite (30g)
- 132
Descrizione
When I type a paired tag, for example:
```tsx
```
If I then add a slash at the end of the opening tag to make it self-closing:
```tsx
```
The editor leaves the redundant closing tag untouched, resulting in broken/invalid markup.
https://github.com/user-attachments/assets/b4335989-09ba-423c-a79e-3f6a69c0275f
**Expected behavior:**
```tsx
```
https://github.com/user-attachments/assets/b9a5a910-5927-48ff-bbbd-0036d96e03c1
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Reproduce the issue with the TSX example in the report by adding a slash to the opening tag, then trace the editor behavior responsible for paired-tag handling. Done means converting to without leaving the redundant closing tag; add or run a regression test if the relevant test location is found.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- typescript
- Ambito
- tooling
- Tipo di issue
- Bug
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Stato di attività
- Attiva
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 58/100