microsoft / microsoft/TypeScript
No semantic token assigned to import names, but available for export
Nessuno ha ancora preso questa issue.
- Lingua principale
- Go
- Stelle
- 111k
- Fork
- 14.4k
- Merge medio
- 1g 19h
- PR unite (30g)
- 117
Descrizione
🔍 Search Terms
import(in the FAQ)is:issue is:open No semantic token importis:issue is:open No highlight import
✅ Viability Checklist
- This wouldn't be a breaking change in existing TypeScript/JavaScript code
- This wouldn't change the runtime behavior of existing JavaScript code
- This could be implemented without emitting different JS based on the types of the expressions
- This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, new syntax sugar for JS, etc.)
- This isn't a request to add a new utility type: https://github.com/microsoft/TypeScript/wiki/No-New-Utility-Types
- This feature would agree with the rest of our Design Goals: https://github.com/Microsoft/TypeScript/wiki/TypeScript-Design-Goals
⭐ Suggestion
This is an issue originally from: https://github.com/typescript-language-server/typescript-language-server/issues/842 and https://github.com/microsoft/vscode/issues/202224.
The issue is confirmed not to be an issue from TypeScript Language Server by its' developer/maintainer, and it is suggested to be posted here by VSCode'sdeveloper/maintainer.
This feature request is asking for the implementation of the semantic highlighting for member imported in the import statement.
📃 Motivating Example
When export a name, there is semantic token assigned. Such as the Compiler is assigned with class.
For import, there seems to be no semantic token available.
And it is also predictable that import using this way, will also get no correct semantic token assigned.
💻 Use Cases
- What do you want to use this for?
Bring better coding experience.
- What shortcomings exist with current approaches?
Currently no precise token is assigned to the imported members, no semantic token is assigned.
- What workarounds are you using in the meantime?
As a theme designer, I do not have any other ideas on that, and I believe this could be solved by language's implementation of this feature.
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
Inizia riproducendo gli esempi di importazione ed esportazione in un editor con l’evidenziazione semantica di TypeScript abilitata, quindi traccia il modo in cui vengono prodotti i token semantici per i membri importati. L’issue non indica file sorgente né test, quindi individua il punto di ingresso pertinente per la generazione dei token del language service e aggiungi una copertura che mostri l’assegnazione dei token prevista.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- typescript
- Ambito
- compilers
- Tipo di issue
- Funzionalità
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 30/100