Javascript – How to get current month last and first date in nodejs
I am trying to get the first and last date of the month by the following code:- let d = new Date(); let month = d.getMonth() + 1; console.log(month); let firstDate = new Date(d.getFullYear(), d.getMonth() + 1); let lastDate =…