How to get date in JSON format with Node.js

1 Answer

0 votes
const json = new Date().toJSON();

console.log(json);


   
  
  
/*
run:
  
2022-03-15T07:35:23.110Z
  
*/

 



answered Mar 15, 2022 by avibootz

Related questions

1 answer 128 views
1 answer 179 views
1 answer 172 views
1 answer 163 views
1 answer 142 views
...