newlinetostring

0.0.1 • Public • Published

##NewLine Node Module

Pass it a string and an optional boolean to return a string with a new line ('\n') appended or prepended to the string.

var nl = require('newLine');

var str = 'String to have a new line concated';

console.log(nl(str)); // 'String to have a new line concated\n'
console.log(nl(str, true)); // '\nString to have a new line concated'

To run tests

npm install -g mocha

mocha tests/newLineTests.js

###Install from Github

npm install git://github.com/madole/newLine.git

Package Sidebar

Install

npm i newlinetostring

Weekly Downloads

2

Version

0.0.1

License

ISC

Last publish

Collaborators

  • madole