# non-breaking-spaces

> Js module boilerPlate

Latest version **1.3.0** (published 2016-10-29) · MIT license · 0 weekly downloads

## Install

```sh
npm install non-breaking-spaces
pnpm add non-breaking-spaces
yarn add non-breaking-spaces
bun add non-breaking-spaces
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.3.0 |
| Published | 2016-10-29 |
| First published | 2016-10-29 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Stéphane Tessier |
| Maintainers | stephane-tessier |

## Links

- npm: https://www.npmjs.com/package/non-breaking-spaces
- Repository: https://github.com/stephane-tessier/non-breaking-spaces
- Homepage: https://github.com/stephane-tessier/non-breaking-spaces#readme
- Issues: https://github.com/stephane-tessier/non-breaking-spaces/issues
- npm.io page: https://npm.io/package/non-breaking-spaces

## Recent versions

- 1.3.0 (latest) — 2016-10-29
- 1.2.0 — 2016-10-29

## README

# Library

The description of the library.

## Installation and Usage

### Installation

To install this javascript module.

```bash
npm install non-breaking-spaces
```

### Usage

Convert text and HTML so that white spaces before ponctuation are transformed into non-breaking spaces (`&nbsp;`).

```javascript
// import CommonJS
var nonBreakingSpaces = require('non-breaking-spaces');

var text = nonBreakingSpaces.noBreak('Ce texte nécessite une petite correction !');
// Ce texte nécessite une petite correction&nbsp;!
```


or with EcmaScript6:
```javascript
// import ES6 Module
import {noBreak as nonBreakingSpaces} from 'non-breaking-spaces';

var text = nonBreakingSpaces('Ce texte nécessite une petite correction !');
// Ce texte nécessite une petite correction&nbsp;!
```

You may also want to change the replacer:
```javascript
nonBreakingSpaces.setOptions('replacer', '&#160;');
// or
nonBreakingSpaces.setOptions({
  replacer: '\\u00a0'
});
```

---
_Source: https://npm.io/package/non-breaking-spaces · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
