UNPKG

842 BTypeScriptView Raw
1// Type definitions for pad 1.1
2// Project: https://github.com/wdavidw/node-pad#readme
3// Definitions by: Mohamed Hegazy <https://github.com/mhegazy>
4// windware <https://github.com/windware>
5// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
6
7export = pad;
8
9/** left pad */
10declare function pad(length: number, text: string, char?: string): string;
11// tslint:disable-next-line unified-signatures
12declare function pad(length: number, text: string, options?: { char?: string, colors?: boolean, strip?: boolean }): string;
13/** Right pad */
14declare function pad(text: string, length: number, char?: string): string;
15// tslint:disable-next-line unified-signatures
16declare function pad(text: string, length: number, options?: { char?: string, colors?: boolean, strip?: boolean }): string;
17
18declare namespace pad {}