# left-pad/left-pad

:arrow_left: String left pad -- deprecated, use String​.prototype​.pad​Start()

Repository: https://github.com/left-pad/left-pad
Canonical: https://ross.abutalabs.com/products/left-pad
Language: JavaScript
License: MIT
License Family: permissive
Topics: left-pad, leftpad, left, padding, pad, string-manipulation
Archived: true
Last push: 2019-04-19T14:16:20+00:00

## Health v2 (maintenance only)
Score: 10/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 4555, "days_push": 2693, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases, archived
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1305, forks 140 (observed 2026-08-28T04:04:18.642338+00:00)

## What it is
A tiny JavaScript utility for left-padding strings to a given length, famous from the 2016 npm ecosystem incident. It is deprecated since native String.prototype.padStart covers the same functionality.

## Use cases
- pad strings with leading characters in old Node.js versions
- zero-pad numbers like IDs or dates
- align text output in CLI tools
- maintain legacy code that depends on left-pad

## When to choose
- you are on a very old JavaScript environment without String.prototype.padStart
- you must keep an existing dependency working in legacy code

## When to avoid
- starting any new project - use the built-in String.prototype.padStart instead
- you need Unicode-aware padding beyond the BMP plane

## Facets
- artifact type: library
- maturity: abandoned
- function: serialization
- domain: developer-tools, programming-languages
- platform: -
- tags: string-manipulation, padding, deprecated, npm, nodejs, javascript

## Member repositories
- left-pad/left-pad (main) score 10

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:18.642338+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T04:51:03.129521+00:00, confidence not recorded.
  - readme: https://github.com/left-pad/left-pad (fetched 2026-08-28T04:04:18.642338+00:00, sha 662703d6d934)
- Data as of 2026-08-30T08:39:29.467469+00:00.
