Issue
I am using angular 7 and momentjs ^2.6. I am facing an issue with momentjs in UAT server dev apps build.
I have three servers
- DEV
- QA
- UAT
I am using dev-ops management for build and deploy process. Everything is working fine in local and DEV and QA
But momentjs throwing an error in UAT server.
Error: moment is not a function
But it is working fine if i am doing rebuild for UAT.
Does anyone have any idea for this issue? Sometimes moment is working fine but sometimes it is not working. If it is not working then if I do rebuild then its working fine in UAT.
Solution
Change your code inside the package.json file.
Delete node_modules and package-lock.json from your directory.
than change the version and run NPM Install
"moment-timezone": "^0.5.7",
TO
"moment-timezone": "0.5.23",
Answered By - surendra kumar
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.