Big update!Introducing GitHub Bot Commands. Learn more
Socket
Log inBook a demo

strip-indent

Package Overview
Dependencies
1
Maintainers
1
Versions
9
Issues
File Explorer

Advanced tools

strip-indent

Strip leading whitespace from each line in a string

    4.0.0latest

Version published
Maintainers
1
Weekly downloads
20,140,492
decreased by-11.54%

Weekly downloads

Changelog

Source

Breaking

  • Require Node.js 12 bbc7f4c
  • This package is now pure ESM. Please read this.

https://github.com/sindresorhus/strip-indent/compare/v3.0.0...v4.0.0

Readme

Source

strip-indent

Strip leading whitespace from each line in a string

The line with the least number of leading whitespace, ignoring empty lines, determines the number to remove.

Useful for removing redundant indentation.

Install

$ npm install strip-indent

Usage

import stripIndent from 'strip-indent'; const string = '\tunicorn\n\t\tcake'; /* unicorn cake */ stripIndent(string); /* unicorn cake */
Get professional support for this package with a Tidelift subscription
Tidelift helps make open source sustainable for maintainers while giving companies
assurances about security, maintenance, and licensing for their dependencies.

Keywords

FAQs

What is strip-indent?

Strip leading whitespace from each line in a string

Is strip-indent popular?

The npm package strip-indent receives a total of 16,053,219 weekly downloads. As such, strip-indent popularity was classified as popular.

Is strip-indent well maintained?

We found that strip-indent demonstrated a not healthy version release cadence and project activity because the last version was released a year ago.It has 1 open source maintainer collaborating on the project.

Last updated on 03 May 2021

Did you know?

Socket installs a Github app to automatically flag issues on every pull request and report the health of your dependencies. Find out what is inside your node modules and prevent malicious activity before you update the dependencies.

Install Socket
Socket

Product

Subscribe to our newsletter

Get open source security insights delivered straight into your inbox. Be the first to learn about new features and product updates.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc