Learn about our RFC process, Open RFC meetings & more.Join in the discussion! »

@simmo/widower

1.0.2 • Public • Published

Widower

npm downloads Travis

Often when working with responsive designs, text will wrap leaving a widowed word on a new line. This JavaScript function replaces the last space with a non breaking space.

Install

npm i @simmo/widower

Usage

const widower = require('widow-killer')
 
widower('Hello world')
// => Hello\u00A0world

MIT © Mike Simmonds

Install

npm i @simmo/widower

DownloadsWeekly Downloads

36

Version

1.0.2

License

MIT

Unpacked Size

3 kB

Total Files

4

Last publish

Collaborators

  • avatar