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 138 views
1 answer 185 views
1 answer 179 views
1 answer 166 views
1 answer 144 views
...