Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript zero pad

const str = "5";
str.padStart(4, "0"); // "0005"
 
PREVIOUS NEXT
Tagged: #javascript #pad
ADD COMMENT
Topic
Name
7+5 =