Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js date of yesterday

let today = new Date();
let yesterday = new Date();

yesterday.setDate(today.getDate() - 1);

console.log('Today: ' + today);
console.log('Yesterday: ' + yesterday);
Source by javascriptf1.com #
 
PREVIOUS NEXT
Tagged: #js #date #yesterday
ADD COMMENT
Topic
Name
4+9 =