Files
30-seconds-of-code/test/JSONToDate/JSONToDate.js

4 lines
165 B
JavaScript

module.exports = JSONToDate = arr => {
const dt = new Date(parseInt(arr.toString().substr(6)));
return `${dt.getDate()}/${dt.getMonth() + 1}/${dt.getFullYear()}`;
};