Reputation: 43923
I have this in my typescript project
import * as schedule from "node-schedule";
import * as ACTIONS from "../../../actions";
The bottom one resolves, but the top one does not. It is a node package I got from doing npm install node-schedule
. I get
Cannot find module 'node-schedule' or its corresponding type declarations.ts(2307)
How can I import that?
Upvotes: 0
Views: 311
Reputation: 250
You need to install its types package..
npm install --save @types/node-schedule
Upvotes: 2