In one of our Laravel projects, after upgrading dependencies, the docker build suddenly started throwing an error of moment.js.
On debugging, I noticed that moment.js was now in maintenance mode and they recommend using different libraries as an alternative.
We've gathered a few alternatives that you can use in your projects.
Here's what you'll learn.
- Get the year, month, date, day, and time
- First and Last day of the month
- Add and Subtract day, month, year, time
- Get and Set the timezone for the date
- Get dates in various formats
For implementation detail, check out our blog.