visual studio - Was sind die Build-Konfigurationsoptionen für ein TypeScript-Projekt?
Wenn ich ein neues "HTMLWeb App"-Projekt erstelle, erhalte ich eine .csproj mit einigen Standardoptionen im Projekt-XML für TypeScript. Wo kann ich eine Liste aller möglichen TypeScript-Build-Optionen finden?
Die Suche nach den Namen der 3 Optionen, die derzeit in meinem Projekt sind, wie z. B. "TypeScriptIncludeComments", ergab keine Ergebnisse bei Google.
Antwort #1
Ich habe die Liste der Optionen in der .targets-Datei gefunden, die mit der TypeScript-Installation geliefert wurde. Hier ist die vollständige Liste der Optionen mit dem Befehlszeilenargument, das tatsächlich an "tsc.exe" (den TypeScript-Compiler) gesendet wird.
- TypeScriptKommentareEinschließen .....
--comments - TypeScript erzeugt Deklarationen .....
--declaration - TypeScriptModuleKind .....
--module $ (TypeScriptModuleKind) - TypeScriptIncludeDefaultLib .....
--nolib - TypeScriptOutFile .....
--out $ (TypeScriptOutFile) - TypeScript-Quellkarte .....
--sourcemap - TypeScriptZiel .....
--target $ (TypeScriptZiel) - TypeScriptAdditionalFlags .....
$ (TypeScriptAdditionalFlags)
Antwort #2
Aktualisierung zu Guptas Antwort für Visual Studio 2015 RC. Die Datei Microsoft.TypeScript.targets befindet sich jetzt in C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\TypeScript.
- TypeScriptKommentareEntfernen .....
--removeComments - TypeScriptNoImplicitAny .....
--noImplicitAny - TypeScript erzeugt Deklarationen .....
--declaration - TypeScriptModuleKind .....
--module "$ (TypeScriptModuleKind)" - TypeScriptOutFile .....
--out "$ (TypeScriptOutFile)" - TypeScriptOutDir .....
--outDir "$ (TypeScriptOutDir)" - TypeScript-SourceMap .....
--sourcemap - TypeScriptTarget .....
--target $ (TypeScriptTarget) - TypeScriptNoResolve .....
--noResolve - TypeScriptZusätzlicheFlags .....
$ (TypeScriptZusätzlicheFlags) - TypeScriptMapRoot .....
--mapRoot "$ (TypeScriptMapRoot)" - TypeScriptSourceRoot .....
--sourceRoot "$ (TypeScriptSourceRoot)" - TypeScriptCodePage .....
--codepage $ (TypeScriptCodePage) - TypeScriptCharset .....
--charset $ (TypeScriptCharset) - TypeScriptEmitBOM .....
--emitBOM - TypeScriptNoLib .....
--noLib - TypeScriptConstEnums beibehalten .....
--preserveConstEnums - TypeScriptUnterdrückeImpliziteAnyIndexFehler .....
--suppressImplicitAnyIndexErrors