U need to add moment in dependency list in package.json.
For example when u create any application, you will be doing npm i to install all the dependencies(dependencies mentioned in package.json), when you do npm i moment --save will add the module in the dependencies list