nl2br-x
v0.1.2
Published
JS module for converting newlines to line breaks in BEMHTML and BEMTREE syntaxe
Downloads
11
Maintainers
Readme
nl2brX
JS module for converting newlines to line breaks in BEMHTML and BEMTREE syntax.
Install
$ npm install nl2br-x
Example
const nl2brX = require('nl2br-x');
console.log(nl2brX(`Hello
world
!!!`)); // ['Hello', {tag: 'br'}, 'world', {tag: 'br'}, '!!!']