SHARE
TWEET

Untitled

a guest Mar 23rd, 2019 63 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. //Get Date
  2. //Pass Date string and return date in format: dd/MM/yyyy
  3. const getDate = (date) => {
  4.     let dateString = date.substr(6);
  5.     let currentTime = new Date(parseInt(dateString));
  6.     let month = currentTime.getMonth() + 1;
  7.     let day = currentTime.getDate();
  8.     let year = currentTime.getFullYear();
  9.     return day + "/" + month + "/" + year;
  10. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top