microsoft / microsoft/TypeScript
Document quick fix (or whatever it's officially called)
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- Go
- Sterne
- 111k
- Forks
- 14.3k
- Ø Merge
- 1 T. 19 Std.
- Gemergte PRs (30 T.)
- 117
Beschreibung
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
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Beginne mit dem Vergleich des tsc-Verhaltens über die Befehlszeile mit dem TypeScript server und den im Issue beschriebenen Editor-Integrationen. Verfolge die code-fix-Terminologie in der TypeScript-Codebasis und ihrem message JSON und ermittle dann, ob die Lücke allein durch Dokumentation abgedeckt ist oder ob auch das Auflisten von Vorschlägen in tsc erforderlich ist; abgeschlossen bedeutet, dass die Terminologie und das unterstützte Verhalten eindeutig dokumentiert sind.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- typescript
- Bereich
- cli, documentation
- Issue-Typ
- Dokumentation
- Schwierigkeit
- 5/5
- Geschätzter Aufwand
- Über eine Woche
- Aktivitätsstatus
- Veraltet
- Klarheit
- Muss geklärt werden
- Anfängerfreundlichkeit
- 25/100