{"_id":"list-item","_rev":"35505","name":"list-item","description":"Generate a single formatted list item, allowing you to easily generate lists with proper indentation, bullets, numbers or other leading characters.","dist-tags":{"latest":"2.0.0"},"maintainers":[{"name":"adjohnson916","email":""},{"name":"jonschlinkert","email":""}],"time":{"modified":"2023-09-20T22:02:52.000Z","created":"2015-02-21T16:13:37.282Z","2.0.0":"2018-07-05T05:53:59.442Z","1.1.1":"2015-12-20T16:37:28.108Z","1.1.0":"2015-12-20T16:29:28.817Z","1.0.1":"2015-08-08T22:42:17.325Z","0.1.2":"2015-02-22T00:37:16.411Z","0.1.1":"2015-02-21T16:20:16.234Z","0.1.0":"2015-02-21T16:13:37.282Z"},"users":{},"author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/list-item.git"},"versions":{"2.0.0":{"name":"list-item","description":"Generate a single formatted list item, allowing you to easily generate lists with proper indentation, bullets, numbers or other leading characters.","version":"2.0.0","homepage":"https://github.com/jonschlinkert/list-item","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"maintainers":[{"name":"adjohnson916","email":""},{"name":"jonschlinkert","email":""}],"contributors":[{"name":"Anders D. Johnson","url":"https://github.com/adjohnson916"}],"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/list-item.git"},"bugs":{"url":"https://github.com/jonschlinkert/list-item/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=4"},"scripts":{"test":"mocha"},"dependencies":{"fill-range":"^6.0.0","is-number":"^7.0.0"},"devDependencies":{"gulp-format-md":"^1.0.0","mocha":"^5.2.0","romanize":"^1.1.1"},"keywords":["bullet","format","item","list","list-item","markdown","numbered","numerals","ordered","roman","test","unordered"],"verb":{"toc":false,"layout":"default","tasks":["readme"],"plugins":["gulp-format-md"],"related":{"list":["deromanize","fill-range","randomatic","romanize","to-regex-range"]},"reflinks":["fill-range","randomatic","romanize"],"lint":{"reflinks":true}},"gitHead":"d6dac43cd8f2e6796403392926cdc32b4e7a7c14","_id":"list-item@2.0.0","_npmVersion":"6.1.0","_nodeVersion":"10.0.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"dist":{"shasum":"368e5bce05bcc6d0e64a766929fe58d366ddd6f2","size":4315,"noattachment":false,"key":"/list-item/-/list-item-2.0.0.tgz","tarball":"http://name.csiicloud.com:7001/list-item/download/list-item-2.0.0.tgz"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/list-item_2.0.0_1530770039351_0.386643312271127"},"_hasShrinkwrap":false,"publish_time":1530770039442,"_cnpm_publish_time":1530770039442},"1.1.1":{"name":"list-item","description":"Generate a single formatted list item, allowing you to easily generate lists with proper indentation, bullets, numbers or other leading characters.","version":"1.1.1","homepage":"https://github.com/jonschlinkert/list-item","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"maintainers":[{"name":"adjohnson916","email":""},{"name":"jonschlinkert","email":""}],"contributors":[{"name":"Anders D. Johnson","url":"https://github.com/adjohnson916"}],"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/list-item.git"},"bugs":{"url":"https://github.com/jonschlinkert/list-item/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"expand-range":"^1.8.1","extend-shallow":"^2.0.1","is-number":"^2.1.0","repeat-string":"^1.5.2"},"devDependencies":{"mocha":"*","romanize":"^0.1.0","should":"*"},"keywords":["bullet","format","item","list","list-item","markdown","numbered","numerals","ordered","roman","test","unordered"],"verb":{"related":{"list":["deromanize","expand-range","fill-range","randomatic","romanize","to-regex-range"]},"plugins":["gulp-format-md"],"reflinks":["expand-range","randomatic","romanize"],"layout":"default"},"gitHead":"26f9ef24523c2374acffd97b7627c217c7fce7c0","_id":"list-item@1.1.1","_shasum":"0c65d00e287cb663ccb3cb3849a77e89ec268a56","_from":".","_npmVersion":"3.3.6","_nodeVersion":"5.0.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"dist":{"shasum":"0c65d00e287cb663ccb3cb3849a77e89ec268a56","size":3849,"noattachment":false,"key":"/list-item/-/list-item-1.1.1.tgz","tarball":"http://name.csiicloud.com:7001/list-item/download/list-item-1.1.1.tgz"},"directories":{},"publish_time":1450629448108,"_cnpm_publish_time":1450629448108,"_hasShrinkwrap":false},"1.1.0":{"name":"list-item","description":"Generate a single formatted list item, allowing you to easily generate lists with proper indentation, bullets, numbers or other leading characters.","version":"1.1.0","homepage":"https://github.com/jonschlinkert/list-item","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"maintainers":[{"name":"adjohnson916","email":""},{"name":"jonschlinkert","email":""}],"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/list-item.git"},"bugs":{"url":"https://github.com/jonschlinkert/list-item/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"expand-range":"^1.8.1","extend-shallow":"^2.0.1","is-number":"^2.1.0","repeat-string":"^1.5.2"},"devDependencies":{"mocha":"*","romanize":"^0.1.0","should":"*"},"keywords":["bullet","format","item","list","list-item","markdown","numbered","numerals","ordered","roman","test","unordered"],"verb":{"related":{"list":["deromanize","expand-range","fill-range","randomatic","romanize","to-regex-range"]},"plugins":["gulp-format-md"],"reflinks":["expand-range","randomatic","romanize"],"layout":"default"},"gitHead":"45ff3f06e72266a147c50d1beb42e38650dab92d","_id":"list-item@1.1.0","_shasum":"d6b826d65bbd02ac9358db20aed2b84de2dd2317","_from":".","_npmVersion":"3.3.6","_nodeVersion":"5.0.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"dist":{"shasum":"d6b826d65bbd02ac9358db20aed2b84de2dd2317","size":3845,"noattachment":false,"key":"/list-item/-/list-item-1.1.0.tgz","tarball":"http://name.csiicloud.com:7001/list-item/download/list-item-1.1.0.tgz"},"directories":{},"publish_time":1450628968817,"_cnpm_publish_time":1450628968817,"_hasShrinkwrap":false},"1.0.1":{"name":"list-item","description":"Generate a single formatted list item, allowing you to easily generate lists with proper indentation, bullets, numbers or other leading characters.","version":"1.0.1","homepage":"https://github.com/jonschlinkert/list-item","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/list-item.git"},"bugs":{"url":"https://github.com/jonschlinkert/list-item/issues"},"maintainers":[{"name":"adjohnson916","email":""},{"name":"jonschlinkert","email":""}],"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"expand-range":"^1.8.1","is-number":"^2.0.2","repeat-string":"^1.5.2"},"devDependencies":{"mocha":"*","romanize":"^0.1.0","should":"*","verb":"git://github.com/verbose/verb.git"},"keywords":["bullet","format","item","list","list-item","markdown","numbered","numerals","ordered","roman","test","unordered"],"verb":{"related":{"list":["fill-range","expand-range","to-regex-range","randomatic","romanize","deromanize"]}},"gitHead":"7c75648a1f9656bceee243aa9efab7353be2f4e2","_id":"list-item@1.0.1","_shasum":"1764d1c48fdda75be7e51bc394d7076fb4280448","_from":".","_npmVersion":"2.12.1","_nodeVersion":"0.12.6","_npmUser":{"name":"adjohnson916","email":"adjohnson916@gmail.com"},"dist":{"shasum":"1764d1c48fdda75be7e51bc394d7076fb4280448","size":3735,"noattachment":false,"key":"/list-item/-/list-item-1.0.1.tgz","tarball":"http://name.csiicloud.com:7001/list-item/download/list-item-1.0.1.tgz"},"directories":{},"publish_time":1439073737325,"_cnpm_publish_time":1439073737325,"_hasShrinkwrap":false},"0.1.2":{"name":"list-item","description":"Generate a single formatted list item, allowing you to easily generate lists with proper indentation, bullets, numbers or other leading characters.","version":"0.1.2","homepage":"https://github.com/jonschlinkert/list-item","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"https://github.com/jonschlinkert/list-item"},"bugs":{"url":"https://github.com/jonschlinkert/list-item/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"expand-range":"^1.8.1","is-number":"^1.1.0","repeat-string":"^1.5.0"},"devDependencies":{"mocha":"*","romanize":"^0.1.0","should":"*"},"keywords":["bullet","format","item","list","list-item","markdown","numbered","numerals","ordered","roman","test","unordered"],"gitHead":"153877f81c053d421f0378244b383ce2b3aa1009","_id":"list-item@0.1.2","_shasum":"4c2dbacfdc4d2e7c22adec314ce506e8d4b3dcd3","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"adjohnson916","email":""},{"name":"jonschlinkert","email":""}],"dist":{"shasum":"4c2dbacfdc4d2e7c22adec314ce506e8d4b3dcd3","size":3149,"noattachment":false,"key":"/list-item/-/list-item-0.1.2.tgz","tarball":"http://name.csiicloud.com:7001/list-item/download/list-item-0.1.2.tgz"},"directories":{},"publish_time":1424565436411,"_cnpm_publish_time":1424565436411,"_hasShrinkwrap":false},"0.1.1":{"name":"list-item","description":"Generate a single formatted list item, allowing you to easily generate lists with proper indentation, bullets, numbers or other leading characters.","version":"0.1.1","homepage":"https://github.com/jonschlinkert/list-item","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"https://github.com/jonschlinkert/list-item"},"bugs":{"url":"https://github.com/jonschlinkert/list-item/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"expand-range":"^1.8.1","is-number":"^1.1.0","repeat-string":"^1.5.0"},"devDependencies":{"mocha":"*","romanize":"^0.1.0","should":"*"},"keywords":["bullet","format","item","list","list-item","markdown","numbered","numerals","ordered","roman","test","unordered"],"gitHead":"e91ff75539fa2d1a14bcd0f598028669408d641c","_id":"list-item@0.1.1","_shasum":"5efba1bcd11a6ab569e8b3575ee9aadbbc7fc0f2","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"adjohnson916","email":""},{"name":"jonschlinkert","email":""}],"dist":{"shasum":"5efba1bcd11a6ab569e8b3575ee9aadbbc7fc0f2","size":3002,"noattachment":false,"key":"/list-item/-/list-item-0.1.1.tgz","tarball":"http://name.csiicloud.com:7001/list-item/download/list-item-0.1.1.tgz"},"directories":{},"publish_time":1424535616234,"_cnpm_publish_time":1424535616234,"_hasShrinkwrap":false},"0.1.0":{"name":"list-item","description":"Generate a single formatted list item, allowing you to easily generate lists with proper indentation, bullets, numbers or other leading characters.","version":"0.1.0","homepage":"https://github.com/jonschlinkert/list-item","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"https://github.com/jonschlinkert/list-item"},"bugs":{"url":"https://github.com/jonschlinkert/list-item/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"expand-range":"^1.8.1","is-number":"^1.1.0","repeat-string":"^1.5.0"},"devDependencies":{"mocha":"*","romanize":"^0.1.0","should":"*"},"keywords":[],"gitHead":"c3d4772045144987090c28518c483fddcc52b9f5","_id":"list-item@0.1.0","_shasum":"6a9ebf096673e7d3f6dbc83659ef8c2d7745418f","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"adjohnson916","email":""},{"name":"jonschlinkert","email":""}],"dist":{"shasum":"6a9ebf096673e7d3f6dbc83659ef8c2d7745418f","size":2951,"noattachment":false,"key":"/list-item/-/list-item-0.1.0.tgz","tarball":"http://name.csiicloud.com:7001/list-item/download/list-item-0.1.0.tgz"},"directories":{},"publish_time":1424535217282,"_cnpm_publish_time":1424535217282,"_hasShrinkwrap":false}},"readme":"# list-item [![NPM version](https://img.shields.io/npm/v/list-item.svg?style=flat)](https://www.npmjs.com/package/list-item) [![NPM monthly downloads](https://img.shields.io/npm/dm/list-item.svg?style=flat)](https://npmjs.org/package/list-item) [![NPM total downloads](https://img.shields.io/npm/dt/list-item.svg?style=flat)](https://npmjs.org/package/list-item) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/list-item.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/list-item)\n\n> Generate a single formatted list item, allowing you to easily generate lists with proper indentation, bullets, numbers or other leading characters.\n\nPlease consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support.\n\n## Install\n\nInstall with [npm](https://www.npmjs.com/):\n\n```sh\n$ npm install --save list-item\n```\n\n## Usage\n\n```js\nconst listitem = require('list-item');\n```\n\n## Examples\n\n**Basic list**\n\nGenerate a list using default bullets and indentation:\n\n```js\nconst listitem = require('list-item');\nconst li = listitem();\n\nlet list = ['a', 'b', 'c', 'd', 'e'].map((ele, i) => li(i, ele));\nconsole.log(list.join('\\n'));\n```\n\nResults in:\n\n```\n- a\n  * b\n    + c\n      - d\n        * e\n```\n\n**Roman numerals**\n\nGenerate roman numerals in increments of 10.\n\n```js\nconst listitem = require('list-item');\nconst romanize = require('romanize');\n\n// specify `chars` to pass to fill-range, and use the callback \n// to modify generated numerals\nconst li = listitem({ chars: '1..100..10' }, (indent, ch) => {\n  return indent + romanize(ch) + '.';\n});\n\n// generate a formatted list!\nlet list = ['a', 'b', 'c', 'd', 'e'].map((ele, i) => li(i, ele));\nconsole.log(list.join('\\n'));\n```\n\nResults in:\n\n```\nI. a\n  XI. b\n    XXI. c\n      XXXI. d\n        XLI. e\n```\n\n## API\n\n### [listitem](index.js#L39)\n\nReturns a function to generate a plain-text/markdown list-item, allowing options to be cached for subsequent calls.\n\n**Params**\n\n* `options` **{Object}**: pass options to customize list item characters, indentation, etc.\n* `options.nobullet` **{Boolean}**: Pass true if you only want the list iten and identation, but no bullets.\n* `options.indent` **{String}**: The amount of leading indentation to use. default is ``.\n* `options.chars` **{String|Array}**: If a string is passed, [fill-range](https://github.com/jonschlinkert/fill-range) will be used to generate an array of bullets (visit [fill-range](https://github.com/jonschlinkert/fill-range) to see all options.) Or directly pass an array of bullets, numbers, letters or other characters to use for each list item. Default `['-', '*', '+']`\n* `fn` **{Function}**: pass a function [fill-range](https://github.com/jonschlinkert/fill-range) to modify the bullet for an item as it's generated. See the [examples](#examples).\n* `returns` **{String}**: returns a formatted list item\n\n**Example**\n\n```js\nconst li = listitem(options);\n\nli(0, 'Level 0 list item');\n//=> '- Level 0 list item'\n\nli(1, 'Level 1 list item');\n//=> '  * Level 1 list item'\n\nli(2, 'Level 2 list item');\n//=> '    + Level 2 list item'\n```\n\n## Release History\n\n### 2.0.0 - July 5, 2018\n\n**Breaking changes**\n\n* The callback signature has changed to `(indent, char, level)`.\n\n## About\n\n<details>\n<summary><strong>Contributing</strong></summary>\n\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).\n\n</details>\n\n<details>\n<summary><strong>Running Tests</strong></summary>\n\nRunning and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:\n\n```sh\n$ npm install && npm test\n```\n\n</details>\n\n<details>\n<summary><strong>Building docs</strong></summary>\n\n_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_\n\nTo generate the readme, run the following command:\n\n```sh\n$ npm install -g verbose/verb#dev verb-generate-readme && verb\n```\n\n</details>\n\n### Related projects\n\nYou might also be interested in these projects:\n\n* [deromanize](https://www.npmjs.com/package/deromanize): Convert roman numerals to arabic numbers (useful for books, outlines, documentation, slide decks, etc) | [homepage](https://github.com/jonschlinkert/deromanize \"Convert roman numerals to arabic numbers (useful for books, outlines, documentation, slide decks, etc)\")\n* [fill-range](https://www.npmjs.com/package/fill-range): Fill in a range of numbers or letters, optionally passing an increment or `step` to… [more](https://github.com/jonschlinkert/fill-range) | [homepage](https://github.com/jonschlinkert/fill-range \"Fill in a range of numbers or letters, optionally passing an increment or `step` to use, or create a regex-compatible range with `options.toRegex`\")\n* [randomatic](https://www.npmjs.com/package/randomatic): Generate randomized strings of a specified length using simple character sequences. The original generate-password. | [homepage](https://github.com/jonschlinkert/randomatic \"Generate randomized strings of a specified length using simple character sequences. The original generate-password.\")\n* [romanize](https://www.npmjs.com/package/romanize): Convert numbers to roman numerals (useful for books, outlines, documentation, slide decks, etc) | [homepage](https://github.com/jonschlinkert/romanize \"Convert numbers to roman numerals (useful for books, outlines, documentation, slide decks, etc)\")\n* [to-regex-range](https://www.npmjs.com/package/to-regex-range): Pass two numbers, get a regex-compatible source string for matching ranges. Validated against more than… [more](https://github.com/micromatch/to-regex-range) | [homepage](https://github.com/micromatch/to-regex-range \"Pass two numbers, get a regex-compatible source string for matching ranges. Validated against more than 2.78 million test assertions.\")\n\n### Contributors\n\n| **Commits** | **Contributor** | \n| --- | --- |\n| 18 | [jonschlinkert](https://github.com/jonschlinkert) |\n| 7 | [adjohnson916](https://github.com/adjohnson916) |\n\n### Author\n\n**Jon Schlinkert**\n\n* [LinkedIn Profile](https://linkedin.com/in/jonschlinkert)\n* [GitHub Profile](https://github.com/jonschlinkert)\n* [Twitter Profile](https://twitter.com/jonschlinkert)\n\n### License\n\nCopyright © 2018, [Jon Schlinkert](https://github.com/jonschlinkert).\nReleased under the [MIT License](LICENSE).\n\n***\n\n_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on July 05, 2018._","_attachments":{},"homepage":"https://github.com/jonschlinkert/list-item","bugs":{"url":"https://github.com/jonschlinkert/list-item/issues"},"license":"MIT"}