Created
July 14, 2017 02:23
-
-
Save charpeni/c19b4947feb561d070a63163da2ba6b8 to your computer and use it in GitHub Desktop.
ES8 padStart
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
'abc'.padStart(10); // " abc" | |
'abc'.padStart(10, "foo"); // "foofoofabc" | |
'abc'.padStart(6,"123465"); // "123abc" | |
'abc'.padStart(8, "0"); // "00000abc" | |
'abc'.padStart(1); // "abc" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment