SHARE
TWEET

Untitled

a guest Jul 21st, 2019 70 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function formatDate(date) {
  2.     const hour = date.getHours();
  3.     const minute = date.getMinutes();
  4.     const second = date.getSeconds();
  5.  
  6.     return (`${hour}:${minute}:${second}`);
  7.   }
  8.  
  9.   const prettyDate = useMemo(() => formatDate(currentDate), [currentDate]);
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
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top