1var currentTimeInSeconds=Math.floor(Date.now()/1000); //unix timestamp in seconds
2var currentTimeInMilliseconds=Date.now(); // unix timestamp in milliseconds
1var today = new Date().toLocaleDateString(undefined, {
2 day: '2-digit',
3 month: '2-digit',
4 year: 'numeric',
5 hour: '2-digit',
6 minute: '2-digit',
7 second: '2-digit'
8})
9