Created
December 17, 2022 20:50
-
-
Save manavm1990/5525171a3889aa18c7f29d4a2f92c955 to your computer and use it in GitHub Desktop.
MM:SS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function formatMinutesSeconds(time) { | |
return `${Math.floor(time / 60)}:${(time % 60).toString().padStart(2, "0")}`; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment