Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign uptsconfig.json does not work with VS 2015 #3124
Comments
This comment has been minimized.
This comment has been minimized.
|
tsconfig.json files are not currently working in VS2015. It's something @paulvanbrenk is working on. |
This comment has been minimized.
This comment has been minimized.
|
Any work around for the time being? I need to specify modules to AMD. |
This comment has been minimized.
This comment has been minimized.
|
No guaranteed workaround, you can try adding a TypeScriptModuleKind element to a propertygroup, with amd or commonjs specified.. not sure if that gets correctly communicated to the compiler. |
paulvanbrenk
added this to the
TypeScript 1.5.2 milestone
May 12, 2015
paulvanbrenk
added
the
Bug
label
May 12, 2015
paulvanbrenk
self-assigned this
May 12, 2015
This comment has been minimized.
This comment has been minimized.
|
Thanks that seems to work. |
This comment has been minimized.
This comment has been minimized.
boxofnotgoodery
commented
May 17, 2015
|
+1 for this to work in VS2015 RC without workarounds. |
This comment has been minimized.
This comment has been minimized.
|
This will work in the final release of VS 2015. |
paulvanbrenk
added
the
Visual Studio
label
May 18, 2015
mhegazy
added
Suggestion
Committed
and removed
Bug
labels
May 19, 2015
This comment has been minimized.
This comment has been minimized.
mhegazy
commented
May 19, 2015
|
Updating the label to suggestion as this is not a bug level change; this does not change the plan of shipping this in the next public VS release. |
This comment has been minimized.
This comment has been minimized.
|
Checked in the code to enable this scenario in VS 2015 |
paulvanbrenk
closed this
May 20, 2015
This comment has been minimized.
This comment has been minimized.
afaayerhan
commented
Jul 20, 2015
|
just got VS 2015 RTM now but the tsconfig is not working. and when you change module system it just does not work. it defaults to commonjs. and if you remove TypeScriptModuleKind it cannot compile without --module flag |
This comment has been minimized.
This comment has been minimized.
|
What kind of project are you using? For VS 2015 RTM tsconfig.json based configuration is only supported for ASP.NET v5 and Cordova Projects. |
This comment has been minimized.
This comment has been minimized.
afaayerhan
commented
Jul 20, 2015
|
njsproj |
This comment has been minimized.
This comment has been minimized.
|
Yes, that's a currently unsupported project type. The behavior you're seeing is expected. We are planning support for additional project types, but nothing concrete at the moment. |
This comment has been minimized.
This comment has been minimized.
afaayerhan
commented
Jul 20, 2015
|
thanks. it would be great if njsproj would be supported and also for tsconfig files sync with ItemGroup typescriptCompile includes. |
This comment has been minimized.
This comment has been minimized.
|
That's exactly one of the problems we run into.. we don't want to have to keep the 2 files in sync. As long as the files are edited in Visual Studio we would be ok, but the moment one of the files is edited outside of Visual Studio the files would be out of sync and we would have a problem getting them back in agreement. |
This comment has been minimized.
This comment has been minimized.
Jak3b0
commented
Jul 24, 2015
|
I'm trying to use the tsconfig.json inside an empty ASP.NET vNext project and it is not being used. I have to set the properties inside a PropertyGroup in the .xproj file... Is there any steps I need to do in order to make it work? @paulvanbrenk, as you mentionned in a previous reply, this should work right? |
This comment has been minimized.
This comment has been minimized.
|
What does your project look like?
|
This comment has been minimized.
This comment has been minimized.
jannavarro
commented
Aug 6, 2015
|
@paulvanbrenk you mentioned "For VS 2015 RTM tsconfig.json based configuration is only supported for ASP.NET v5 and Cordova Projects." In VS 2015 there is a project for Html Application with TypeScript. Will this be supported? |
This comment has been minimized.
This comment has been minimized.
|
We are looking at making the experience better for all projects, including the Html App with TypeScript.. not sure about the time line though. |
This comment has been minimized.
This comment has been minimized.
dazinator
commented
Sep 15, 2015
|
tsconfig.json is not being honored for me (new ASP.NET v5 project.) |
This comment has been minimized.
This comment has been minimized.
mhegazy
commented
Sep 15, 2015
|
@dazinator, for now it needs to be under the scripts folder. but we have a fix for this in the next release. so bear with us for a little bit longer. |
This comment has been minimized.
This comment has been minimized.
dazinator
commented
Sep 15, 2015
|
@mhegazy ok thats fine - will give that a try. Thanks :) |
This comment has been minimized.
This comment has been minimized.
oryol
commented
Nov 4, 2015
|
I use latest (1.6.3 TypeScript language services), VS 2015 and ASP .Net Betta8. I have FrontendApp folder in the root of web project with tsconfig.json. It contains compiler options and links to files with TS definitions. I also use WebPack + ts-loader to build frontend application and it builds successfully. But Visual Studio code analyzer shows errors in the TypeScript files for imports of modules which are declared in the definition files. If I add references like
then errors are disappearing. But all these files are already declared in the tsconfig.json so I don't want to have two sources of these files. What is even more interesting that I have several modules (external) and I added reference comments only to one of them (the main one). If I reopen project and open some other TypeScript file (not main) - Visual Studio shows errors. If I open main TS file after that and wait a few seconds then errors disappear (in all TS files). And after each project reopen I need to open main TS file and wait few seconds. Is it possible just to use files list with definitions from tsconfig.json without including reference comments? |
This comment has been minimized.
This comment has been minimized.
|
@oryol Please see this wikipage about using I think the reason you're seeing what you're seeing is that we only check for tsconfig.json files in the scripts folder. |
This comment has been minimized.
This comment has been minimized.
oryol
commented
Nov 4, 2015
|
So, is it possible to use tsconfig.json in other folders (not in "Scripts")? If not - are you going to support such scenarios and when can we expect such feature? |
This comment has been minimized.
This comment has been minimized.
|
@oryol No, not in TypeScript 1.7 (or earlier). However I'm right now working on making the Caveat: Any features don't actually exist until they're checked-in/shipped, and schedules can change at a moments notice. |
This comment has been minimized.
This comment has been minimized.
oryol
commented
Nov 4, 2015
|
Thank you for reply! |
This comment has been minimized.
This comment has been minimized.
defyjoy
commented
Mar 6, 2016
|
Does this still work for *.csproj files ? I opened a new blank asp.net application and tried to make it work with tsconfig.json .The project I chose in 2015 was But it seems the VS completely ignores the tsconfig.json. My project structure somewhat looks like this Note : I am using typescript v1.8.2 |
This comment has been minimized.
This comment has been minimized.
mhegazy
commented
Mar 7, 2016
|
@defyjoy can you try the latest (https://github.com/Microsoft/TypeScript/releases/tag/v1.8.7), and if you run into issues, please file a new issue and provide a project we can look at. |
This comment has been minimized.
This comment has been minimized.
|
@defyjoy Can you make sure TypeScript shows in Help > About |
This comment has been minimized.
This comment has been minimized.
dehghani-mehdi
commented
Jan 18, 2017
|
Doesn't work here, I'm using |
This comment has been minimized.
This comment has been minimized.
dazinator
commented
Jan 18, 2017
|
When using VS2015, put the tsconfig file in a "Scripts" folder. Otherwise I don't think VS will find it or honour it. |
This comment has been minimized.
This comment has been minimized.
dehghani-mehdi
commented
Jan 18, 2017
|
@dazinator that isn't really good way to deal with config file, I always rename |
This comment has been minimized.
This comment has been minimized.
dazinator
commented
Jan 18, 2017
•
|
@dehghani-mehdi - yep I know. I also think it's a poor, but that is how the VS project system (vs2015) supports typescript projects as far as I know. This should help @defyjoy. If you want to handle typescript project compilation outside VS using |
This comment has been minimized.
This comment has been minimized.
dazinator
commented
Jan 18, 2017
|
Also - if you do decide to use command line <TypeScriptCompileBlocked>true</TypeScriptCompileBlocked> |
This comment has been minimized.
This comment has been minimized.
dehghani-mehdi
commented
Jan 19, 2017
|
@dazinator Thanks for the note, for now I just add |



OnurGumus commentedMay 12, 2015
I am trying to give options to typescript namely trying tell how to load modules from VS. For new ASP.NET 5 templates this option simply not available, worse typescript 1.5 does not honor tsconfig.json either so what should I do ?