Create and format the current hour with JS

PHOTO EMBED

Sat Jul 02 2022 06:08:42 GMT+0000 (Coordinated Universal Time)

Saved by @jen_magpantay #javascript #react.js

const createdAt = new Date().toLocaleTimeString("pt-br", {
  hour: '2-digit',
  minute: '2-digit',
  second: '2-digit',
})
content_copyCOPY