{"name":"eslint-rule-documentation","version":"1.0.2","description":"Find the url for the documentation of an ESLint rule","license":"MIT","repository":{"type":"git","url":"git+https://github.com/jfmengels/eslint-rule-documentation.git"},"author":{"name":"Jeroen Engels","email":"jfm.engels@gmail.com","url":"github.com/jfmengels"},"engines":{"node":">=4.0.0"},"scripts":{"test":"xo && ava"},"files":["index.js","plugins.json"],"keywords":["eslint","eslintplugin","eslint-plugin","plugin","plugins","rule","rules","doc","documentation"],"devDependencies":{"ava":"^0.15.2","xo":"^0.16.0"},"xo":{"space":2},"gitHead":"55d5127a83937184c5653429dd46e39eb77a365f","bugs":{"url":"https://github.com/jfmengels/eslint-rule-documentation/issues"},"homepage":"https://github.com/jfmengels/eslint-rule-documentation#readme","_id":"eslint-rule-documentation@1.0.2","_shasum":"1435cee2072bbe979257ff1c8e90a128eb132050","_from":".","_npmVersion":"3.10.3","_nodeVersion":"6.5.0","_npmUser":{"name":"jfmengels","email":"jfm.engels@gmail.com"},"dist":{"shasum":"1435cee2072bbe979257ff1c8e90a128eb132050","tarball":"http://registry-npm.ywwl.com/eslint-rule-documentation/download/eslint-rule-documentation-1.0.2.tgz","integrity":"sha512-oeJqmI78kasy+EELGPhGMsiwtxPxq9K03XDMPS+OVE3vj7ZFrZI1iD2E7spLu7HAFbnbhoMDccwV50aXpMohjg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDnirabRgu6xMhIIxTjqySwd7N7qy4wiNdI/wYnp/gK/QIhAJnKyxf1t8O6qhYf4RNOzAVijHqMqvUT2Uuf8cSVyQoI"}],"size":2580,"noattachment":false,"key":"/eslint-rule-documentation/-/eslint-rule-documentation-1.0.2.tgz"},"maintainers":[{"name":"jfmengels","email":"jfm.engels@gmail.com"}],"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/eslint-rule-documentation-1.0.2.tgz_1474362716376_0.9713342827744782"},"directories":{},"readme":"# eslint-rule-documentation [![Build Status](https://travis-ci.org/jfmengels/eslint-rule-documentation.svg?branch=master)](https://travis-ci.org/jfmengels/eslint-rule-documentation)\r\n\r\n> Find the url for the documentation of an [ESLint] rule\r\n\r\n\r\n## Install\r\n\r\n```\r\n$ npm install --save eslint-rule-documentation\r\n```\r\n\r\n\r\n## Usage\r\n\r\n```js\r\nconst getRuleURI = require('eslint-rule-documentation');\r\n\r\n// find url for core rules\r\ngetRuleURI('no-var');\r\n// => { found: true, url: 'https://eslint.org/docs/rules/no-var' }\r\n\r\n// find url for known plugins\r\ngetRuleURI('import/no-unresolved');\r\n// => { found: true, url: 'https://github.com/benmosher/eslint-plugin-import/blob/master/docs/rules/no-unresolved.md' }\r\n\r\n// If the plugin is not known, get a link to help improve this\r\ngetRuleURI('unknown-foo/bar');\r\n// => { found: false, url: 'https://github.com/jfmengels/eslint-rule-documentation/blob/master/contributing.md' }\r\n```\r\n\r\n## Contributing\r\n\r\nIf you find a plugin that you use is not in the [list of supported plugins](./plugins.json), please consider adding it to the project by following the instructions [here](./contributing.md).\r\n\r\n\r\n## API\r\n\r\n### getRuleURI(ruleId)\r\n\r\n\r\n\r\n#### ruleId\r\n\r\nType: `string`\r\n\r\nId of an [ESLint] rule.\r\n\r\nExamples:\r\n- core rule: `no-var`\r\n- plugin rule: `import/no-unresolved` (from the [eslint-plugin-import] plugin).\r\n\r\n#### returns\r\n\r\nType: `object`\r\n\r\n```js\r\n{\r\n  found: <boolean>,\r\n  url: <string>\r\n}\r\n```\r\n\r\n- `found`: `true` if the rule is an ESLint core rule, or a rule of a known plugin, `false` otherwise.\r\n- `url`: if `found` is `true`, url of the documentation of a rule. If `found` is `false`, url of the [contribution guidelines](./contributing.md).\r\n\r\n## Thanks\r\n\r\nSpecial thanks to the team behind [linter-eslint] for the original work, and the people who contributed there.\r\n\r\n\r\n## License\r\n\r\nMIT © [Jeroen Engels](https://github.com/jfmengels)\r\n\r\n[eslint-plugin-import]: https://github.com/benmosher/eslint-plugin-import\r\n[ESLint]: https://eslint.org/\r\n[linter-eslint]: https://github.com/AtomLinter/linter-eslint\r\n","publish_time":1474362719092,"_cnpm_publish_time":1474362719092,"dist-tags":{"latest":"1.0.23"}}