trim-off-newlines
v1.0.3
Published
Similar to String#trim() but removes only newlines
Downloads
1,379,423
Readme
trim-off-newlines ![Build Status](https://travis-ci.org/stevemao/trim-off-newlines.svg?branch=master)
Similar to
String#trim()
but removes only newlines
Install
$ npm install --save trim-off-newlines
Usage
var trimOffNewlines = require('trim-off-newlines');
trimOffNewlines('\n\nunicorns\n\n');
//=> 'unicorns'
Related
trim-left
- Similar toString#trim()
but removes only whitespace on the lefttrim-right
- Similar toString#trim()
but removes only whitespace on the right
License
MIT © Steve Mao