summaryrefslogtreecommitdiff
path: root/bin/wiki/ImportarDesdeURL/node_modules/condense-whitespace/readme.md
blob: f080c6d983d3a687a7fed2d74458f171ade34375 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# condense-whitespace [![Build Status](https://travis-ci.org/sindresorhus/condense-whitespace.svg?branch=master)](https://travis-ci.org/sindresorhus/condense-whitespace)

> Remove leading, trailing, and repeated whitespace from a string


## Install

```
$ npm install condense-whitespace
```


## Usage

```js
const condenseWhitespace = require('condense-whitespace');

condenseWhitespace('  foo bar     baz ');
//=> 'foo bar baz'
```


## Related

- [`trim-repeated`](https://github.com/sindresorhus/trim-repeated) - Trim a consecutively repeated substring: `foo--bar---baz` → `foo-bar-baz`


## License

MIT © [Sindre Sorhus](https://sindresorhus.com)