I have a number let say 9. But I need it as String \"09\".
I know i can write my own logic. But I am looking for a implicit util function which can pad it.
I
With the latest Typescript, you can do:
let myStr:string = padLeft('123', '0', 6); // '000123' padLeft(text:string, padChar:string, size:number): string { return (String(padChar).repeat(size) + text).substr( (size * -1), size) ; }