{"id":15649539,"url":"https://github.com/a-tokyo/eslint-plugin-react-hooks-docs","last_synced_at":"2025-08-25T13:12:55.134Z","repository":{"id":217720647,"uuid":"744694948","full_name":"a-tokyo/eslint-plugin-react-hooks-docs","owner":"a-tokyo","description":"🚨 Eslint plugin to enforce react hooks documentation","archived":false,"fork":false,"pushed_at":"2024-01-18T20:37:41.000Z","size":132,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-06T16:08:41.037Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/a-tokyo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":".github/CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":".github/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":".github/SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-01-17T20:24:33.000Z","updated_at":"2024-01-23T17:55:54.000Z","dependencies_parsed_at":"2024-01-18T02:38:58.578Z","dependency_job_id":"2bd202cc-eb58-4ab6-97f3-0fed14153e8c","html_url":"https://github.com/a-tokyo/eslint-plugin-react-hooks-docs","commit_stats":null,"previous_names":["a-tokyo/eslint-plugin-hooks-docs"],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/a-tokyo%2Feslint-plugin-react-hooks-docs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/a-tokyo%2Feslint-plugin-react-hooks-docs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/a-tokyo%2Feslint-plugin-react-hooks-docs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/a-tokyo%2Feslint-plugin-react-hooks-docs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/a-tokyo","download_url":"https://codeload.github.com/a-tokyo/eslint-plugin-react-hooks-docs/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246258871,"owners_count":20748573,"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-10-03T12:30:05.835Z","updated_at":"2025-03-30T00:13:19.539Z","avatar_url":"https://github.com/a-tokyo.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# eslint-plugin-react-hooks-docs\n\n🚨 Eslint plugin to enforce react hooks documentation.\n\n\u003cbr\u003e\n\n\u003ca href=\"https://npmjs.com/package/eslint-plugin-react-hooks-docs\"\u003e\n  \u003cimg src=\"https://img.shields.io/npm/v/eslint-plugin-react-hooks-docs.svg\"\u003e\u003c/img\u003e\n  \u003cimg src=\"https://img.shields.io/npm/dt/eslint-plugin-react-hooks-docs.svg\"\u003e\u003c/img\u003e\n\u003c/a\u003e\n\u003ca href=\"https://twitter.com/intent/follow?screen_name=ahmad_tokyo\"\u003e\u003cimg src=\"https://img.shields.io/twitter/follow/ahmad_tokyo.svg?label=Follow%20@ahmad_tokyo\" alt=\"Follow @ahmad_tokyo\"\u003e\u003c/img\u003e\u003c/a\u003e\n\n\u003cbr\u003e\n\n## Installation\n\n```bash\nnpm i eslint eslint-plugin-react-hooks-docs --save-dev\n```\nOR\n```bash\nyarn add -D eslint eslint-plugin-react-hooks-docs\n```\n\n## Usage\n\n### Extending recommended configuration\nYou can extend the recommended configuration by adding 'plugin:eslint-plugin-react-hooks-docs/recommended' to the `extends` array in your `eslintrc`.\n```\nextends: ['plugin:eslint-plugin-react-hooks-docs/recommended'],\n```\n\n### Manually applying the rules\nAdd `react-hooks-docs` to the plugins section of your `.eslintrc` configuration file. You can omit the `eslint-plugin-` prefix:\n\n```json\n{\n  \"plugins\": [\"react-hooks-docs\"]\n}\n```\n\nThen configure the rules you want to use under the rules section. Note that the 2nd param is optional extra configurations.\n\n```json\n{\n  \"rules\": {\n    \"react-hooks-docs/docs\": [\n      2,\n      {\n        \"skipDeclarations\": true,\n        \"skipHooks\": []\n      }\n    ]\n  }\n}\n```\n\n## Rules\n\n### docs\nEnforces documentation to exist in the form of a comment for react hooks calls.\n\n**Options:**\n- skipDeclarations: boolean - doesn't enforce the rule on hook declarations eg: `const [state, setState] = useState(0);`.\n- skipHooks: Array\u003cstring\u003e - doesn't enforce the rule on the hooks passed to in this array eg: `useCustomHook`\n\n\n\u003cp align=\"center\"\u003e\n  \u003csub\u003eBuilt with ❤︎ by \u003ca href=\"https://ahmedtokyo.com\"\u003eAhmed Tokyo\u003c/a\u003e\n  \u003cbr/\u003e\n\u003c/p\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fa-tokyo%2Feslint-plugin-react-hooks-docs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fa-tokyo%2Feslint-plugin-react-hooks-docs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fa-tokyo%2Feslint-plugin-react-hooks-docs/lists"}