{"id":13671557,"url":"https://github.com/mcecot/markdown-it-checkbox","last_synced_at":"2025-05-07T20:31:27.211Z","repository":{"id":28832329,"uuid":"32355913","full_name":"mcecot/markdown-it-checkbox","owner":"mcecot","description":"Plugin to create checkboxes for markdown-it markdown parser.","archived":false,"fork":false,"pushed_at":"2021-04-07T03:40:11.000Z","size":47,"stargazers_count":36,"open_issues_count":8,"forks_count":22,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-11-10T07:03:58.291Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mcecot.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-03-16T22:07:32.000Z","updated_at":"2024-08-29T10:06:33.000Z","dependencies_parsed_at":"2022-08-07T14:00:50.977Z","dependency_job_id":null,"html_url":"https://github.com/mcecot/markdown-it-checkbox","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcecot%2Fmarkdown-it-checkbox","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcecot%2Fmarkdown-it-checkbox/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcecot%2Fmarkdown-it-checkbox/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcecot%2Fmarkdown-it-checkbox/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mcecot","download_url":"https://codeload.github.com/mcecot/markdown-it-checkbox/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225013480,"owners_count":17407151,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-02T09:01:12.990Z","updated_at":"2024-11-17T23:04:59.485Z","avatar_url":"https://github.com/mcecot.png","language":"JavaScript","readme":"# markdown-it-checkbox [![NPM version][npm-image]][npm-url]\n[![Build Status][travis-image]][travis-url] [![Coverage Status][coveralls-image]][coveralls-url] [![Dependency Status][depstat-image]][depstat-url] [![devDependency Status][devdepstat-image]][devdepstat-url]\n\n\u003e Plugin to create checkboxes for [markdown-it](https://github.com/markdown-it/markdown-it) markdown parser.\n\nThis plugin allows to create checkboxes for tasklists as discussed [here](http://talk.commonmark.org/t/task-lists-in-standard-markdown/41).\n\n\n\n## Usage\n\n## Install\n\nnode.js, browser:\n\n```bash\nnpm install markdown-it-checkbox --save\nbower install markdown-it-checkbox --save\n```\n\n## Use\n\n```js\nvar md = require('markdown-it')()\n            .use(require('markdown-it-checkbox'));\n\nmd.render('[ ] unchecked') // =\u003e\n// \u003cp\u003e\n//  \u003cinput type=\"checkbox\" id=\"checkbox0\"\u003e\n//  \u003clabel for=\"checkbox0\"\u003eunchecked\u003c/label\u003e\n// \u003c/p\u003e\n\nmd.render('[x] checked') // =\u003e\n// \u003cp\u003e\n//  \u003cinput type=\"checkbox\" id=\"checkbox0\" checked=\"true\"\u003e\n//  \u003clabel for=\"checkbox0\"\u003echecked\u003c/label\u003e\n// \u003c/p\u003e\n```\n\n_Differences in browser._ If you load script directly into the page, without\npackage system, module will add itself globally as `window.markdownitCheckbox`.\n\n## Options\n\n```js\nvar md = require('markdown-it')()\n            .use(require('markdown-it-checkbox'),{\n              divWrap: true,\n              divClass: 'cb',\n              idPrefix: 'cbx_'\n            });\n\nmd.render('[ ] unchecked') // =\u003e\n// \u003cp\u003e\n//  \u003cdiv classname=\"cb\"\u003e\n//    \u003cinput type=\"checkbox\" id=\"cbx_0\"\u003e\n//    \u003clabel for=\"cbx_0\"\u003eunchecked\u003c/label\u003e\n//  \u003c/div\u003e\n// \u003c/p\u003e\n```\n\n## divWrap\n\n* **Type:** `Boolean`\n* **Default:** `false`\n\nwrap div arround checkbox. this makes it possible to use it for example with [Awesome Bootstrap Checkbox](https://github.com/flatlogic/awesome-bootstrap-checkbox/).\n\n## divClass\n\n* **Type:** `String`\n* **Default:** `checkbox`\n\nclassname of div wrapper. will only be used if `divWrap` is enanbled.\n\n## idPrefix\n\n* **Type:** `String`\n* **Default:** `checkbox`\n\nthe id of the checkboxs input contains the prefix and an incremental number starting with `0`. i.e. `checkbox1` for the 2nd checkbox.\n\n\n## License\n\n[MIT License](https://github.com/mcecot/markdown-it-checkbox/blob/master/LICENSE) © 2015 Markus Cecot\n\n[npm-url]: https://npmjs.org/package/markdown-it-checkbox\n[npm-image]: https://img.shields.io/npm/v/markdown-it-checkbox.svg\n\n[travis-url]: http://travis-ci.org/mcecot/markdown-it-checkbox\n[travis-image]: https://secure.travis-ci.org/mcecot/markdown-it-checkbox.svg?branch=master\n\n[coveralls-url]: https://coveralls.io/r/mcecot/markdown-it-checkbox\n[coveralls-image]: https://img.shields.io/coveralls/mcecot/markdown-it-checkbox.svg\n\n[depstat-url]: https://david-dm.org/mcecot/markdown-it-checkbox\n[depstat-image]: https://david-dm.org/mcecot/markdown-it-checkbox.svg\n\n[devdepstat-url]: https://david-dm.org/mcecot/markdown-it-checkbox#info=devDependencies\n[devdepstat-image]: https://david-dm.org/mcecot/markdown-it-checkbox/dev-status.svg\n","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmcecot%2Fmarkdown-it-checkbox","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmcecot%2Fmarkdown-it-checkbox","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmcecot%2Fmarkdown-it-checkbox/lists"}