crip-pad

1.0.0 • Public • Published

crip-pad Build Status

Left pad a string with crips

Install

$ npm install --save crip-pad

Usage

const cripPad = require('crip-pad');
 
cripPad('TIMMAAYY', 9);
//=> '♿️TIMMAAYY'

API

cripPad(input, length)

Pads input with crips on the left side if it's shorter than length. Padding crips are truncated if they exceed length.

input

Type: string

String to pad.

length

Type: number
Default: 0

Padding length.

License

MIT © Johnie Hjelm

Package Sidebar

Install

npm i crip-pad

Weekly Downloads

1

Version

1.0.0

License

MIT

Last publish

Collaborators

  • johnie