</>PackageGraphPackageGraph

strip-indent

npmv4.1.1TypeScript

Strip leading whitespace from each line in a string

Safe to adopt

Yes — strip-indent scores well across adoption, maintenance, weight, supply chain, and licensing. No download data reported for this package yet. Last published 332 days ago. 2 releases in the last 2 years.

  • ?Adoption: grade ?, Not reported by this registry.

    No download data reported for this package yet.

  • BMaintenance: grade B, Good.

    Last published 332 days ago. 2 releases in the last 2 years.

  • AWeight: grade A, Excellent.

    Zero runtime dependencies, about 4.6 KB installed.

  • BSupply chain: grade B, Good.

    This package has a single maintainer (bus factor of 1).

  • ALicense: grade A, Excellent.

    MIT — permissive, with no copyleft found in the dependency tree.

Grades are computed deterministically from registry metadata collected by PackageGraph — downloads, dependents, publish dates, the resolved dependency tree, maintainer count, and declared licenses. No third-party scores are used.

Install cost

What you actually take on by adding strip-indent to a project.

0
Direct dependencies

Runtime packages this one declares itself.

0
Total installed

Distinct packages in the full runtime tree, deduplicated the way a package manager would.

4.6 KB
Install size

Unpacked size of this package plus its entire runtime tree.

Tree depth

Longest resolved dependency chain below this package.

Compatibility

Node.js
node >=12
Module format
ESM only
TypeScript
Types included
Install scripts
None

Quick start

A usage example from the strip-indent README.

import stripIndent from 'strip-indent';

const string = '\tunicorn\n\t\tcake';
/*
	unicorn
		cake
*/

stripIndent(string);
/*
unicorn
	cake
*/

strip-indent vs the alternatives

Packages solving a similar problem in the npm ecosystem, compared on the signals that drive an adoption decision.

PackageWeekly downloadsDependentsLicenseLast release
strip-indentthis page01MIT11 months ago
redent03MIT1 day ago
strip-bom01MIT1 day ago
strip-json-comments02MIT1 day ago
indent-string94M2MIT1 day ago
escape-string-regexp316.5M8MIT1 day ago

Dependencies

Declared by strip-indent v4.1.1. Runtime dependencies are installed with the package; dev dependencies are not.

Dev (2)

ava ^3.15.0xo ^0.39.1

Used by

Popular packages that depend on strip-indent.

Relationship graph

Dependencies (left) and dependents (right) of strip-indent.

redentstrip-indent
strip-indent dependencies dependents

Frequently installed together

Release history

2 releases in the last two years, typically about 187 days apart.

Recent versions of strip-indent
VersionPublishedSizeLicense
4.1.1latest11 months ago4.6 KBMIT
4.1.01 year ago4.6 KBMIT
4.0.05 years ago3.6 KBMIT
3.0.07 years ago3.2 KBMIT
2.0.010 years agoMIT
1.0.111 years agoMIT
1.0.012 years agoMIT
0.1.312 years agoMIT
0.1.212 years agoMIT
0.1.112 years agoMIT
0.1.012 years agoMIT

Overview

strip-indent is an npm package that strip leading whitespace from each line in a string. It has 1 known dependents in the graph. The latest version is 4.1.1, released under the MIT license.

Who should use it

Teams working in the npm ecosystem who need strip leading whitespace from each line in a string and value a focused solution.

When not to use it

Consider an alternative if you need to or if a more actively-maintained option better fits your npm stack.

Pros

  • Ships TypeScript type definitions.
  • Clear open-source license (MIT).
  • Lean dependency tree (2 direct dependencies).

Cons

  • No significant drawbacks detected from available metadata.

Auto-generated from collected registry metadata. No external claims are inferred.

Maintainers

Keywords

Funding

Frequently asked questions

Should I use strip-indent?

Yes — strip-indent scores well across adoption, maintenance, weight, supply chain, and licensing. No download data reported for this package yet. Last published 332 days ago. 2 releases in the last 2 years.

How do I install strip-indent?

Run `npm install strip-indent` to add strip-indent to your npm project.

What license is strip-indent released under?

strip-indent is distributed under the MIT license.

How popular is strip-indent?

npm does not publish download counts. Within PackageGraph's crawl, 1 known packages depend on strip-indent.

Is strip-indent still maintained?

The most recent release of strip-indent (v4.1.1) was published 11 months ago.

Does strip-indent run install scripts?

No. strip-indent does not define preinstall, install, or postinstall scripts, so installing it does not execute publisher-supplied code.