Starting with Q2 2012, Telerik UI for Windows 8 HTML ships with TypeScript declarations (with types and documentation) for all Telerik controls and utility
types. The following table contains information about which versions of Telerik UI for Windows 8 HTML start
supporting a newer version of TypeScript. Note that until the 1.0 version of TypeScript is
declared, there can be many breaking changes between versions.
Telerik UI version
Q2 2013 SP1(2013.2.716)
How to Use Telerik UI for Windows 8 TypeScript Declarations
You can find the TypeScript declaration of Telerik UI for Windows 8 (telerik.d.ts) in:
The Telerik UI for Windows 8 HTML QX 201X installation folder. By default, it is
~\Program Files (x86)\Telerik\UI for Windows 8 HTML QX 20XX\js.
The js folder in the Dev, Hotfix_Dev and
Source downloadable zip archives
The \~Telerik.UI\js folder of the Telerik UI for Windows 8 HTML NuGet package.
The Telerik namespace is exposed as an internal TypeScript module of the global module and it depends on the WinJS TypeScript declarations. Therefore,
you need to first get them.
The WinJS declarations are provided and supported by the TypeScript development team and you can find them in the
\bin\winjs.d.ts file of the current branch of their CodePlex repository.
In order to use Telerik controls' declarations you need copies and references to both the aforementioned files. For example, suppose
default.ts is the file you are working in from the following folder structure:
To get it working, add the following two lines of code in the beginning of the file.
You now have static typing and API IntelliSense for all Telerik controls at development time:
As of TypeScript 0.9.0.1 you also have event handler IntelliSense: event handler
overloading on constants (the event name), detailed event argument types, etc