5

I want to target ES5 so I setup in my Visual Studio project file:

<PropertyGroup Condition="'$(Configuration)' == 'Debug'">
    <TypeScriptTarget>ES5</TypeScriptTarget>
    <TypeScriptIncludeComments>false</TypeScriptIncludeComments>
    <TypeScriptSourceMap>false</TypeScriptSourceMap>
    <TypeScriptModuleKind>AMD</TypeScriptModuleKind> 
 </PropertyGroup>

But now I am getting error MSB6006: "tsc.exe" exited with code 1. With ES3 I don't get the error.

daniel
  • 34,281
  • 39
  • 104
  • 158
  • What version of typescript is installed? – WiredPrairie Oct 06 '13 at 16:31
  • it is version 0.9.1.1 – daniel Oct 06 '13 at 17:06
  • I'm struggling with this as well, if i get it figured out i will let you know – Gent Oct 06 '13 at 18:57
  • What does the output window say? – Ryan Cavanaugh Oct 07 '13 at 04:11
  • the whole output: `1>C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\TypeScript\Microsoft.TypeScript.targets(74,5): error MSB6006: "tsc.exe" exited with code 1.` – daniel Oct 07 '13 at 08:22
  • 3
    Try turning on verbose logging in your build. That should give you more information about the error. http://sedodream.com/2008/06/16/ChangingBuildVerbosityInVisualStudio.aspx – Alex Dresko Oct 08 '13 at 15:03
  • 0.9.1.1 predates a lot of bug fixing and build support. It also predates the "spec lockdown" and has some incompatibilities with the final TypeScript syntax. If you can, you should probably upgrade your version of TypeScript, particularly to or past 1.0. It may take some upgrade work (particularly due to the default inferred type becoming ``{}`` rather than ``any``). – WorldMaker Oct 30 '14 at 15:04
  • @zoidbergi Did you ever find a solution to this problem? – Gaelan Oct 09 '15 at 06:01
  • not sure, compare your project file to a clean project. delete the suo. Reinstall typescript/VS etc. – daniel Oct 09 '15 at 10:03

1 Answers1

0

Use standard tsconfig.json file in project files tree (VS detect them). BTW same way use for npm config package.json.

Uwe Keim
  • 39,551
  • 56
  • 175
  • 291