3.0.0 • Published 4 years ago
condense-whitespace v3.0.0
condense-whitespace
Remove leading, trailing, and repeated whitespace from a string
Install
$ npm install condense-whitespaceUsage
import condenseWhitespace from 'condense-whitespace';
condenseWhitespace(' foo bar baz ');
//=> 'foo bar baz'Related
trim-repeated- Trim a consecutively repeated substring:foo--bar---baz→foo-bar-baz