Back to Explore

wooorm/trim-lines

GitHub
2 watchersOpen source

Last release:

trim-lines is a small utility that removes initial and final spaces and tabs around line endings in a string, while keeping the line endings themselves. It is useful when you want “markdown-like” whitespace trimming around line breaks without trimming whitespace at the start or end of the entire string.

Project status

  • Actively maintained: No, maintenance appears inactive. The upstream push was in 2022-11-23, and the most recent recorded update here is 3.0.1 from 2022-07-03, which is long before today (2026-06-09).
  • Update cadence: It is not possible to infer a current cadence from this source now, but historically updates happened in bursts (2016-2022), and no recent updates have been shown for roughly several years.

AI summary generated

AI-generated from public sources. May be inaccurate. Report

Recent updates

  • 3.0.1

    Release 3.0.1 is a small patch intended to improve performance of the trimming logic in `trim-lines`. The published notes only mention faster trimming, with no mention of behavioral or compatibility changes.

  • 3.0.0

    Release 3.0.0 updates `trimLines` to handle different newline types (LF, CRLF, and CR) and refactors the implementation for better performance. It also changes whitespace trimming behavior so it no longer removes blank lines.

    BreakingFeatures
  • 2.0.0

    Release 2.0.0 converts the library to an ESM-first setup, adds JSDoc-based type declarations, and refactors the build output. The runtime API is still a single trimLines function, but the module shape and published files changed.

    BreakingFeatures
  • 1.1.3

    Release 1.1.3 claims to only refactor prose. The diff shows documentation wording/formatting tweaks, plus additional project metadata and developer tooling changes (devDependency bumps). No runtime dependencies or library logic changes are present in this diff.

  • 1.1.2

    Release 1.1.2 primarily updates repository-facing details, including adding more README badges and renaming the LICENSE file to lowercase. The actual code diff also includes CI and build tooling changes via package.json and .travis.yml updates, which are not mentioned in the release notes.

    Features
  • 1.1.1

    Release 1.1.1 is presented as a refactor focused on code-style cleanup and README formatting. The diff also includes multiple tooling and CI configuration changes (package.json scripts, devDependency upgrades, and Travis deploy/testing behavior), none of which are mentioned in the release notes.

  • 1.0.0

    This release is version 1.0.0, but the provided release notes contain no change details. No information is available here about new features, bug fixes, breaking changes, or dependency updates.

  • 1.1.0

    Release 1.1.0 primarily modernizes the project setup and removes redundant repository artifacts. The core runtime implementation of trimLines is effectively unchanged, but the release changes what gets published and how browser bundles are built.