{"id":17717713,"url":"https://github.com/mununki/hoodux","last_synced_at":"2026-01-20T07:02:11.070Z","repository":{"id":34923532,"uuid":"191028537","full_name":"mununki/hoodux","owner":"mununki","description":"Hoodux is a helper to replace the React Redux with React hooks","archived":false,"fork":false,"pushed_at":"2022-12-10T18:36:29.000Z","size":2417,"stargazers_count":1,"open_issues_count":22,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-09T07:59:36.137Z","etag":null,"topics":["hooks","react","redux"],"latest_commit_sha":null,"homepage":null,"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/mununki.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2019-06-09T16:17:27.000Z","updated_at":"2019-06-17T04:15:19.000Z","dependencies_parsed_at":"2023-01-15T10:29:49.496Z","dependency_job_id":null,"html_url":"https://github.com/mununki/hoodux","commit_stats":null,"previous_names":["mattdamon108/hoodux"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/mununki/hoodux","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mununki%2Fhoodux","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mununki%2Fhoodux/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mununki%2Fhoodux/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mununki%2Fhoodux/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mununki","download_url":"https://codeload.github.com/mununki/hoodux/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mununki%2Fhoodux/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28597985,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-20T02:08:49.799Z","status":"ssl_error","status_checked_at":"2026-01-20T02:08:44.148Z","response_time":117,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["hooks","react","redux"],"created_at":"2024-10-25T14:29:42.188Z","updated_at":"2026-01-20T07:02:11.054Z","avatar_url":"https://github.com/mununki.png","language":"JavaScript","readme":"# Hoodux\n\n[![npm version](https://badge.fury.io/js/hoodux.svg)](https://badge.fury.io/js/hoodux)\n\nHoodux is a helper to replace the React Redux with React hooks.\n\n### [Demo](https://mattdamon108.github.io/hoodux/)\n\n## Usage\n\n### Install\n\n```shell\n$ npm install hoodux --save\n\nor\n\n$ yarn add hoodux\n```\n\n### API\n\n1. `useHooduxProvider(reducer, initState)`\n\nThis is a hook to generate Hoodux Provider which should be placed on the top level of app. Hoodux provider will populate a state and dispatch to the app's components tree.\n\n2. `useHoodux()`\n\nThis is a hook to pop a state and dispatch to use in any component in your app.\n\n## Example\n\n```js\nimport { useHooduxProvider, useHoodux } from \"hoodux\";\n\nconst initState = {\n  isSignedIn: false,\n  count: 0\n};\n\nconst reducer = (state, action) =\u003e {\n  switch (action.type) {\n    case \"auth\":\n      return { isSignedIn: !state.isSignedIn };\n    case \"changeCount\":\n      return { count: action.payload };\n    default:\n      throw new Error(\"Invalid action type\");\n  }\n};\n\nconst App = () =\u003e {\n  const { HooduxProvider } = useHooduxProvider(reducer, initState);\n  return (\n    \u003cHooduxProvider\u003e\n      \u003cMain /\u003e\n    \u003c/HooduxProvider\u003e\n  );\n};\n\nconst Main = () =\u003e {\n  const { state, dispatch } = useHoodux();\n\n  return (\n    \u003cdiv\u003e\n      \u003cbutton onClick={() =\u003e dispatch({ type: \"auth\" })}\u003eToggle\u003c/button\u003e\n      \u003cbutton onClick={() =\u003e dispatch({ type: \"changeCount\", payload: 5 })}\u003e\n        Change count to 5\n      \u003c/button\u003e\n    \u003c/div\u003e\n  );\n};\n```\n\n## Next to do\n\n- [ ] Add more types\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmununki%2Fhoodux","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmununki%2Fhoodux","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmununki%2Fhoodux/lists"}