Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

padend javascript

const str1 = '123';
str1.padEnd(3, '0');  // "12300"
str1.padEnd(3, '*'); // "123**"
Source by developer.mozilla.org #
 
PREVIOUS NEXT
Tagged: #padend #javascript
ADD COMMENT
Topic
Name
4+1 =