pad: Allow to use a string instead of an options object (#19208)

This commit is contained in:
Andy
2017-08-28 07:19:59 -07:00
committed by GitHub
parent 1834011379
commit b3f1017c61

View File

@@ -6,6 +6,10 @@
export = pad;
/** left pad */
declare function pad(length: number, text: string, char?: string): string;
// tslint:disable-next-line unified-signatures
declare function pad(length: number, text: string, options?: { char?: string, colors?: boolean, strip?: boolean }): string;
/** Right pad */
declare function pad(text: string, length: number, char?: string): string;
// tslint:disable-next-line unified-signatures
declare function pad(text: string, length: number, options?: { char?: string, colors?: boolean, strip?: boolean }): string;