trim-right

Similar to `String#trim()` but removes only whitespace on the right

Deprecated. Use `String#trimEnd()` instead.
Last updated 4 years ago by sindresorhus .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ npm install trim-right 
SYNC missed versions from official npm registry.

trim-right

Similar to String#trim() but removes only whitespace on the right

Install

$ npm install trim-right

Usage

import trimRight from 'trim-right';

trimRight('  unicorn  ');
//=> '  unicorn'

Related

  • trim-left - Similar to String#trim() but removes only whitespace on the left
  • trim-off-newlines - Similar to String#trim() but removes only newlines

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.

Current Tags

  • 2.0.0                                ...           latest (4 years ago)

3 Versions

  • 2.0.0 [deprecated]           ...           4 years ago
  • 1.0.1                                ...           9 years ago
  • 1.0.0                                ...           10 years ago
Maintainers (1)
Downloads
Total 0
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (0)
None
Dev Dependencies (2)

© 2010 - cnpmjs.org x YWFE | Home | YWFE