TypeScript Finding definition files with typescript 2.x


With the 2.x versions of typescript, typings are now available from the npm @types repository. These are automatically resolved by the typescript compiler and are much simpler to use.

To install a type definition you simply install it as a dev dependency in your projects package.json


npm i -S lodash
npm i -D @types/lodash

after install you simply use the module as before

import * as _ from 'lodash'