we can get the milliseconds from 1970 Jan in js for the current date and time
new Date().valueOf() // 1528191046005
form this value (1528191046005) how we can calculate the date and time, is there any way?
we can get the milliseconds from 1970 Jan in js for the current date and time
new Date().valueOf() // 1528191046005
form this value (1528191046005) how we can calculate the date and time, is there any way?
new Date(your_unix_time * 1000) will result with the required Date object
It should just switch back
var x=new Date().valueOf();
var y= new Date(x);
console.log(y.toDateString())