{"id":33166256,"url":"https://github.com/sergiodxa/redux-duck","last_synced_at":"2026-01-14T18:32:06.149Z","repository":{"id":36247580,"uuid":"222559265","full_name":"sergiodxa/redux-duck","owner":"sergiodxa","description":"Helper function to create Redux modules using the ducks-modular-redux proposal","archived":true,"fork":false,"pushed_at":"2022-05-25T15:50:04.000Z","size":900,"stargazers_count":10,"open_issues_count":3,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-31T01:17:42.295Z","etag":null,"topics":["action-payload","duck","helpers","reducer","redux","redux-ducks"],"latest_commit_sha":null,"homepage":"https://github.com/sergiodxa/redux-duck","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/sergiodxa.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"patreon":"sergiodxa","github":"sergiodxa","custom":"https://paypal.me/sergiodxa"}},"created_at":"2019-11-18T22:43:48.000Z","updated_at":"2025-01-24T16:12:14.000Z","dependencies_parsed_at":"2022-09-14T15:02:05.163Z","dependency_job_id":null,"html_url":"https://github.com/sergiodxa/redux-duck","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/sergiodxa/redux-duck","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sergiodxa%2Fredux-duck","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sergiodxa%2Fredux-duck/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sergiodxa%2Fredux-duck/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sergiodxa%2Fredux-duck/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sergiodxa","download_url":"https://codeload.github.com/sergiodxa/redux-duck/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sergiodxa%2Fredux-duck/sbom","scorecard":{"id":812467,"data":{"date":"2025-08-11","repo":{"name":"github.com/sergiodxa/redux-duck","commit":"d10b76dafa550a7d1e344e19e92cdc1640267ed8"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.5,"checks":[{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":0,"reason":"Found 0/2 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/ci.yml:1","Warn: no topLevel permission defined: .github/workflows/publish.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"project is archived","details":["Warn: Repository is archived."],"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:11: update your workflow using https://app.stepsecurity.io/secureworkflow/sergiodxa/redux-duck/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/sergiodxa/redux-duck/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publish.yml:11: update your workflow using https://app.stepsecurity.io/secureworkflow/sergiodxa/redux-duck/publish.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/publish.yml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/sergiodxa/redux-duck/publish.yml/master?enable=pin","Info:   0 out of   4 GitHub-owned GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 28 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"29 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92","Warn: Project is vulnerable to: GHSA-6chw-6frg-f759","Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c","Warn: Project is vulnerable to: GHSA-w573-4hg7-7wgq","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-896r-f27r-55mw","Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h","Warn: Project is vulnerable to: GHSA-6c8f-qphg-qjgp","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-vh95-rmgr-6w4m","Warn: Project is vulnerable to: GHSA-xvch-5gv4-984h","Warn: Project is vulnerable to: GHSA-5fw9-fq32-wv5p","Warn: Project is vulnerable to: GHSA-hrpp-h998-j3pp","Warn: Project is vulnerable to: GHSA-p8p7-x288-28g6","Warn: Project is vulnerable to: GHSA-gcx4-mw62-g8wm","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-h9rv-jmmf-4pgx","Warn: Project is vulnerable to: GHSA-hxcc-f52p-wc94","Warn: Project is vulnerable to: GHSA-4wf5-vphf-c2xc","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6","Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3","Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7","Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-23T13:29:42.612Z","repository_id":36247580,"created_at":"2025-08-23T13:29:42.612Z","updated_at":"2025-08-23T13:29:42.612Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28430842,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T16:38:47.836Z","status":"ssl_error","status_checked_at":"2026-01-14T16:34:59.695Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: 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":["action-payload","duck","helpers","reducer","redux","redux-ducks"],"created_at":"2025-11-16T00:00:38.210Z","updated_at":"2026-01-14T18:32:06.141Z","avatar_url":"https://github.com/sergiodxa.png","language":"TypeScript","funding_links":["https://patreon.com/sergiodxa","https://github.com/sponsors/sergiodxa","https://paypal.me/sergiodxa"],"categories":["Marks"],"sub_categories":["[React - A JavaScript library for building user interfaces](http://facebook.github.io/react)"],"readme":"# redux-duck\n\n![CI Status](https://github.com/sergiodxa/redux-duck/workflows/CI/badge.svg)\n![Publish Status](https://github.com/sergiodxa/redux-duck/workflows/Publish/badge.svg)\n![Dependabot Status](https://api.dependabot.com/badges/status?host=github\u0026repo=sergiodxa/redux-duck)\n[![Maintainability](https://api.codeclimate.com/v1/badges/be75f5fbab018e9e27fa/maintainability)](https://codeclimate.com/github/sergiodxa/redux-duck/maintainability)\n[![Test Coverage](https://api.codeclimate.com/v1/badges/be75f5fbab018e9e27fa/test_coverage)](https://codeclimate.com/github/sergiodxa/redux-duck/test_coverage)\n![license](https://badgen.net/github/license/sergiodxa/redux-duck)\n![releases](https://badgen.net/github/releases/sergiodxa/redux-duck)\n![npm version](https://badgen.net/npm/v/sergiodxa/redux-duck)\n![dependencies](https://badgen.net/david/dep/sergiodxa/redux-duck)\n\nHelper function to create Redux modules using the [ducks-modular-redux](https://github.com/erikras/ducks-modular-redux/) proposal.\n\n## Installation\n\n```sh\nyarn add redux-duck\n```\n\n## API\n\n### Create duck\n\n```ts\nimport { createDuck } from \"redux-duck\";\n\nconst myDuck = createDuck(\"duck-name\", \"application-name\");\n```\n\n- `createDuck` receive 2 arguments, the second argument is optional.\n- The first argument is the duck name.\n- The second, and optional, argument is the application or module name.\n\n### Define action types\n\n```ts\nconst ACTION_TYPE = myDuck.defineType(\"ACTION_TYPE\");\n```\n\n- `defineType` receive just one argument.\n- The argument is the name of the action.\n- The result should be an string like `application-name/duck-name/ACTION_TYPE` or `duck-name/ACTION_TYPE` if the application or module name was not defined.\n\n### Create action creators\n\n```ts\nconst actionType = myDuck.createAction(ACTION_TYPE, false);\n```\n\n- `createAction` receive two arguments, the second argument is optional.\n- The first argument is the action type.\n- The second, and optional, argument is if the action will be an error one.\n- This argument should be the defined action type string.\n- It will return a function who will receive the action payload and meta data and return a valid (FSA compilant) action object.\n- The action creator will receive two optional arguments, one with the action payload and another with the action meta data.\n\n### Create reducer\n\n```ts\nconst initialState = {\n  list: Immutable.List(),\n  data: Immutable.Map()\n};\n\nconst reducer = myDuck.createReducer(\n  {\n    [ACTION_TYPE]: (state, action) =\u003e ({\n      ...state,\n      list: state.list.push(action.payload.id),\n      data: state.map.set(action.payload.id + \"\", action.payload)\n    })\n  },\n  initialState\n);\n```\n\n- `createReducer` receive two arguments, both required.\n- The first argument is an object with the possible action cases.\n- The second argument is the reducer initial state.\n- The first argument should use the previously defined _action types_ as keys.\n- Each key in the first argument object should be a function who will receive the current state and the dispatched action as arguments and return the updated state.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsergiodxa%2Fredux-duck","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsergiodxa%2Fredux-duck","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsergiodxa%2Fredux-duck/lists"}