microsoft / microsoft/TypeScript
Document quick fix (or whatever it's officially called)
Nessuno ha ancora preso questa issue.
- Lingua principale
- Go
- Stelle
- 111k
- Fork
- 14.3k
- Merge medio
- 2g 4h
- PR unite (30g)
- 132
Descrizione
TypeScript Version: 3.3.0-dev.201xxxxx
Search Terms:
code fix
quick fix
suggestion
Code
not entirely applicable, but this is what I had which caused me to get confused
const fs = require("fs");
Expected behavior:
Commandline tsc should behave the same as editor integrations
Actual behavior:
The "quick fix" feature, which appears to be called "code fixes" in the codebase and googling the messages led me to the json file which refers to them as "suggestions", only appears to exist in the typescript server.
As a newcomer this had me extremely confused. I was running tsc on the commandline and getting no errors, but seeing squiggly lines and messages in my editor (atom, in this case).
I was unable to find any documentation about where the message 'require' call may be converted to an import was coming from, or that this was a hint that typescript was able to fix my code for me.
It would also be helpful if the tsc client was able to list the code fix suggestions, even if giving it a way to apply them would be too complex.
Playground Link:
n/a
Related Issues:
none that I could find
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 confrontando il comportamento di tsc dalla riga di comando con il TypeScript server e le integrazioni dell’editor descritte nell’issue. Traccia la terminologia di code-fix nella codebase di TypeScript e nel relativo message JSON, quindi determina se la sola documentazione copre la lacuna o se è necessario anche elencare i suggerimenti in tsc; il lavoro è completato quando la terminologia e il comportamento supportato sono documentati chiaramente.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- typescript
- Ambito
- cli, documentation
- Tipo di issue
- Documentazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Stato di attività
- Ferma
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 25/100