Currently, I am in the process of transitioning an existing project to TypeScript which includes numerous bower and npm dependencies (bower.json and package.json). As mentioned on the tsd github page,
TSD facilitates the discovery and linking of definitions from packages installed via node or bower. By utilizing the link command, your tsd.d.ts file will be updated with paths to files within the node_modules or bower_modules directories.
However, upon executing the tsd link
command following tsd init
, it only displays no (new) packages to link
even though my package.json contains a plethora of modules. This made me realize that perhaps its functionality is different than what I initially assumed.
This particular feature scans through the package.json and bower.json files looking for a typescript element. Within this element, there is a definition or definitions sub-element containing relative path(s) to .d.ts files:
What exactly is the purpose of this link
feature if it doesn't directly fetch type definitions from my package.json? Is it solely meant to extract tsd configurations from my package.json as opposed to my tsd.json file? If so, what is the benefit, other than eliminating the need for the tsd.json file?
If not through tsd link
, I wonder if there exists a more efficient method to automatically incorporate tsd definitions for all my dependencies. It appears somewhat daunting to manually handle each of these.