Installing declaration files

You will find that most of the more popular declaration files that are found on the DefinitelyTyped GitHub repository have a corresponding NuGet package. These packages are named <library>TypeScript.DefinitelyTyped, as a standard naming convention. If we type jquery typescript into the NuGet search box, we will see a list of these DefinitelyTyped packages returned. The NuGet package we are looking for is named jquery.TypeScript.DefinitelyTyped, created by Jason Jarret, and is, at the time of writing, at version 3.1.2, as shown in the following screenshot:

The DefinitelyTyped packages have their own internal version number, and these version numbers do not necessarily match the version of the JavaScript library that you are using.

Installing the jQuery.TypeScript.DefinitelyTyped package will create a typings directory under the Scripts directory, and then include the jquery.d.ts definition file. This directory naming standard has been adopted by the various NuGet package authors.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.16.147.124