Reputation: 1149
I know that TypeScript is new, but just playing around with it.
I have tried converting a few .js files that uses jQuery and for intellisense to work I need to reference the jquery.d.ts file in the top like
/// <reference path="jquery.d.ts" />
That's fine, but then you also need to have the file in the same directory. What i want is to reference typing file globally, instead of relative to the file, so if I move the js file, I don't have to correct the reference path to the typing file.
Is it possible to make them relative to the solution or maybe have it placed in a global folder that is automatically loaded.
I use the web essentials for visual studio 2012, so i get preview and other nice features.
Hope there is a solution for this.
Upvotes: 4
Views: 1240
Reputation: 74909
Global or project relative paths are not supported. There's a feature request for it here:
Absolute root path for reference / import
https://typescript.codeplex.com/workitem/1414
Upvotes: 0
Reputation: 284
In the "Reference Directives" section of this link, it says the following is supported:
/// <reference path="~/Scripts/ScriptFile4.js" />
However, I couldn't get it working for typescript files. I guess it's not supported for typescript.
Upvotes: 1