ersatz-linewrap

0.1.1 • Public • Published

ersatz-linewrap

It somehow wraps lines at about some width.

Usage

var lineWrap = require('ersatz-linewrap'), wrapOpts, text,
  bogusWords = require('ersatz-linewrap/makebogustext');

text = bogusWords(30) +
  '\n    ' + bogusWords(20) +
  '\n' + bogusWords(20);
console.log(lineWrap(text));

console.log('__________\n');

wrapOpts = {
  width: 60,
  hyphen: '<',
  indent: '  >',
  afterWrapped: '¶\n',
};
console.log(lineWrap(text, wrapOpts));

License

ISC

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.1.1
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.1.1
    1
  • 0.1.0
    0

Package Sidebar

Install

npm i ersatz-linewrap

Weekly Downloads

1

Version

0.1.1

License

ISC

Last publish

Collaborators

  • mk-pmb