I ran these commands:
npm install tsd -g
tsd install moment --save
it is also injecting into my module but when i am accessing it it is not recognizing moment.
eg.
import * as moment from 'moment';
Could you please help me out.
I ran these commands:
npm install tsd -g
tsd install moment --save
it is also injecting into my module but when i am accessing it it is not recognizing moment.
eg.
import * as moment from 'moment';
Could you please help me out.
Try this .
npm install @types/moment --save-dev
It is best to install the typescript definition files as developer dependencies
Then import like this
import * as moment from "moment"