{"name":"condense-newlines","description":"Replace extraneous newlines with a single newline, or pass a specified number of newlines to use.","version":"0.1.0","homepage":"https://github.com/jonschlinkert/condense-newlines","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git://github.com/jonschlinkert/condense-newlines.git"},"bugs":{"url":"https://github.com/jonschlinkert/condense-newlines/issues"},"licenses":[{"type":"MIT","url":"https://github.com/jonschlinkert/condense-newlines/blob/master/LICENSE-MIT"}],"keywords":["docs","documentation","generate","generator","markdown","templates","verb"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha -R spec"},"devDependencies":{"verb-tag-jscomments":">= 0.1.4","verb":">= 0.2.6","mocha":"*"},"dependencies":{"arrayify-compact":"^0.1.0"},"_id":"condense-newlines@0.1.0","_shasum":"9b25a137676b783649f9131953945bbf9029895e","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"9b25a137676b783649f9131953945bbf9029895e","tarball":"http://registry-npm.ywwl.com/condense-newlines/download/condense-newlines-0.1.0.tgz","integrity":"sha512-UQMyxRilIVGvrWqVQ5BT/3eI3lK87yXqdK1AxdrQdYjEzr218yoj3wNqPeMt2B7dR/2kur07rUONGRCbtSHpUA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDx+dWXE6++oR0yFukuH4c2cl/hJsZt9rNKNfKOxBWGegIhAN3r/uW9x7QLQx2VkHgH2NIUQ/lqlDH1bQ/WJ7vj/cqZ"}],"size":2739,"noattachment":false,"key":"/condense-newlines/-/condense-newlines-0.1.0.tgz"},"directories":{},"readme":"# condense-newlines [![NPM version](https://img.shields.io/npm/v/condense-newlines.svg?style=flat)](https://www.npmjs.com/package/condense-newlines) [![NPM downloads](https://img.shields.io/npm/dm/condense-newlines.svg?style=flat)](https://npmjs.org/package/condense-newlines) [![Build Status](https://img.shields.io/travis/jonschlinkert/condense-newlines.svg?style=flat)](https://travis-ci.org/jonschlinkert/condense-newlines)\n\nReplace extraneous newlines with a single newline, or pass a specified number of newlines to use.\n\n## Install\n\nInstall with [npm](https://www.npmjs.com/):\n\n```sh\n$ npm install condense-newlines --save\n```\n\n## Usage\n\n```js\nvar condense = require('condense-newlines');\nconsole.log(condense('\\n\\na\\n\\n\\nb\\nc\\r\\n\\r\\nd\\n\\n\\n'));\n//=> '\\na\\nb\\nc\\nd\\n';\n```\n\n## Options\n\n### options.sep\n\nSpecify the separator to use\n\n```js\nconsole.log(condense('\\n\\na\\n\\n\\nb\\nc\\r\\n\\r\\nd\\n\\n\\n', {sep: '\\n\\n'}));\n//=> '\\n\\na\\n\\nb\\n\\nc\\n\\nd\\n\\n';\n```\n\n### options.min\n\nThe minimum number of consecutive newlines to condense.\n\n**Default**\n\n: `2`\n\n```js\nconsole.log(condense('\\n\\na\\n\\n\\nb\\nc\\r\\n\\r\\nd\\n\\n\\n', {min: 2}));\n//=> '\\n\\na\\n\\nb\\n\\nc\\n\\nd\\n\\n';\n```\n\n### options.keepWhitespace\n\nDon't treat whitespace-only lines as newlines.\n\n```js\nconsole.log(condense('\\n\\na\\n\\n      \\nb\\nc\\r\\n\\r\\nd\\n\\n\\n', {\n  keepWhitespace: true, sep: '\\n\\n'\n}));\n\n//=> '\\n\\na\\n\\n      \\nb\\n\\nc\\n\\nd\\n\\n';\n```\n\n## Related projects\n\nYou might also be interested in these projects:\n\n* [arr-union](https://www.npmjs.com/package/arr-union): Combines a list of arrays, returning a single array with unique values, using strict equality… [more](https://www.npmjs.com/package/arr-union) | [homepage](https://github.com/jonschlinkert/arr-union)\n* [array-unique](https://www.npmjs.com/package/array-unique): Return an array free of duplicate values. Fastest ES5 implementation. | [homepage](https://github.com/jonschlinkert/array-unique)\n* [arrayify-compact](https://www.npmjs.com/package/arrayify-compact): Casts the given value to a flatten array, and removes falsey items (similar to lodash… [more](https://www.npmjs.com/package/arrayify-compact) | [homepage](https://github.com/jonschlinkert/arrayify-compact)\n\n## Contributing\n\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/condense-newlines/issues/new).\n\n## Building docs\n\nGenerate readme and API documentation with [verb](https://github.com/verbose/verb):\n\n```sh\n$ npm install verb && npm run docs\n```\n\nOr, if [verb](https://github.com/verbose/verb) is installed globally:\n\n```sh\n$ verb\n```\n\n## Running tests\n\nInstall dev dependencies:\n\n```sh\n$ npm install -d && npm test\n```\n\n## Author\n\n**Jon Schlinkert**\n\n* [github/jonschlinkert](https://github.com/jonschlinkert)\n* [twitter/jonschlinkert](http://twitter.com/jonschlinkert)\n\n## License\n\nCopyright © 2016, [Jon Schlinkert](https://github.com/jonschlinkert).\nReleased under the [MIT license](https://github.com/jonschlinkert/condense-newlines/blob/master/LICENSE).\n\n***\n\n_This file was generated by [verb](https://github.com/verbose/verb), v0.9.0, on April 23, 2016._","publish_time":1405157014116,"_cnpm_publish_time":1405157014116,"dist-tags":{"latest":"0.2.1"}}