7

Using the tsd command I ran this command tsd install node

It install the definitions file in the typings/node/node.d.ts but I can see that this definition file is for node.js version 4

Node.js v4.x API

How do I install the tsd for node version 5.11.0?

Dmitri
  • 34,780
  • 9
  • 39
  • 55

1 Answers1

5

Seems you can install specific types like this:

npm install --save @types/node@4.0.30

For our project we need to match the version of node supported by aws Lambda (currently 4.0.3).

Not sure how to get the list of available types, but when i put in an incorrect value, the npm feedback listed the available types:

npm ERR! notarget 
["4.0.15-alpha","4.0.16-alpha","4.0.21-alpha","4.0.22-alpha","4.0.23-alpha","4.0.24-alpha","4.0.25-alpha","4.0.26-alpha","4.0.27-alpha","4.0.28-alpha","4.0.29","4.0.30","6.0.31","6.0.32","6.0.33","6.0.34","6.0.35","6.0.36","6.0.37","6.0.38","6.0.39","6.0.40","6.0.41","6.0.42","6.0.43","6.0.44","6.0.45","6.0.46","6.0.47"]

From this I fished out the latest version of 4.x that I needed.

Bruce MacKenzie
  • 101
  • 2
  • 8
  • 4
    You can get a list of the versions available with this command: `npm view @types/node versions` – cartant Nov 15 '16 at 06:59