27 lines
581 B
Markdown
27 lines
581 B
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
|
|
[Home](./index.md) > [@apextoaster/js-utils](./js-utils.md) > [leftPad](./js-utils.leftpad.md)
|
|
|
|
## leftPad() function
|
|
|
|
Prefix `val` with `fill` until it is at least `min` characters.
|
|
|
|
<b>Signature:</b>
|
|
|
|
```typescript
|
|
export declare function leftPad(val: string, min?: number, fill?: string): string;
|
|
```
|
|
|
|
## Parameters
|
|
|
|
| Parameter | Type | Description |
|
|
| --- | --- | --- |
|
|
| val | string | |
|
|
| min | number | |
|
|
| fill | string | |
|
|
|
|
<b>Returns:</b>
|
|
|
|
string
|
|
|