Where are TypeScript definitions for the WinJS library?

Actually why is WinJS not written in TypeScript in the first place?

有帮助吗?

解决方案

The definitions for WinJS are here:

https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/winjs

WinJS pre-dates TypeScript. That's not to say they won't transfer it to TypeScript now given TypeScript 1.0 was officially announced last night.

其他提示

There are also some definitions in the Official TypeScript repository found here: https://typescript.codeplex.com/SourceControl/latest#typings/

They might be the same as the one on DefnitelyTyped but i'm not sure.

It seems WinJS definitions on DefinitelyTyped are not updated which is sad. So best source today is probably WinJS github repo: https://github.com/winjs/winjs/tree/master/typings/winjs

I have a tutorial about when to use DefinitelyTyped vs Typings, as I found both of them to be very confusing.

TypeScript wasn't a think when WinJS was first created as well. Not everyone wants to use TypeScript, so to get web developers on board, I'd imagine that simply using JavaScript is a better starting point than requiring them to learn a new language (TypeScript) on top of learning the WinJS programming model.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top