js datetime add days code example
Example 1: js date add 1 day
let date = new Date();
// add a day
date.setDate(date.getDate() + 1);
Example 2: javascript add days
Date.prototype.addDays = function(days) {
var date = new Date(this.valueOf());
date.setDate(date.getDate() + days);
return date;
}