Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript days until end of month

let dateToday = new Date();
let lastDayOfMonth = new Date(dateToday.getFullYear(), dateToday.getMonth()+1, 0).getDate();
let daysUntilEndOfMonth = lastDayOfMonth - dateToday.getDate();
console.log(daysUntilEndOfMonth)
 
PREVIOUS NEXT
Tagged: #javascript #days #month
ADD COMMENT
Topic
Name
2+6 =