{"id":30580526,"url":"https://github.com/react-component/rate","last_synced_at":"2025-08-29T05:36:39.891Z","repository":{"id":45924535,"uuid":"50573016","full_name":"react-component/rate","owner":"react-component","description":"React Rate","archived":false,"fork":false,"pushed_at":"2025-02-10T03:16:46.000Z","size":6222,"stargazers_count":95,"open_issues_count":16,"forks_count":60,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-08-23T08:59:16.008Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://rate-chi.now.sh","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/react-component.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-01-28T09:47:25.000Z","updated_at":"2025-04-04T04:37:00.000Z","dependencies_parsed_at":"2023-02-09T10:20:19.328Z","dependency_job_id":"abeadb4a-d942-4952-9e3d-f11518a2c2f8","html_url":"https://github.com/react-component/rate","commit_stats":{"total_commits":105,"total_committers":24,"mean_commits":4.375,"dds":0.7619047619047619,"last_synced_commit":"2e41652c6633e5f8bf2e9cdf53c2b6df217f4158"},"previous_names":[],"tags_count":33,"template":false,"template_full_name":null,"purl":"pkg:github/react-component/rate","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/react-component%2Frate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/react-component%2Frate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/react-component%2Frate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/react-component%2Frate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/react-component","download_url":"https://codeload.github.com/react-component/rate/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/react-component%2Frate/sbom","scorecard":{"id":765396,"data":{"date":"2025-08-11","repo":{"name":"github.com/react-component/rate","commit":"1ec5a9dcbd58e0a88eb78d02a2c2e8d81b39995c"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":4.2,"checks":[{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Code-Review","score":3,"reason":"Found 8/24 approved changesets -- score normalized to 3","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":"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":"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":"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/codeql.yml:27: update your workflow using https://app.stepsecurity.io/secureworkflow/react-component/rate/codeql.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql.yml:30: update your workflow using https://app.stepsecurity.io/secureworkflow/react-component/rate/codeql.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql.yml:36: update your workflow using https://app.stepsecurity.io/secureworkflow/react-component/rate/codeql.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql.yml:39: update your workflow using https://app.stepsecurity.io/secureworkflow/react-component/rate/codeql.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/react-component-ci.yml:5: update your workflow using https://app.stepsecurity.io/secureworkflow/react-component/rate/react-component-ci.yml/master?enable=pin","Info:   0 out of   4 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 third-party 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":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Info: jobLevel 'actions' permission set to 'read': .github/workflows/codeql.yml:16","Info: jobLevel 'contents' permission set to 'read': .github/workflows/codeql.yml:17","Warn: no topLevel permission defined: .github/workflows/codeql.yml:1","Warn: no topLevel permission defined: .github/workflows/react-component-ci.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":"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":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"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.md:0","Info: FSF or OSI recognized license: MIT License: LICENSE.md: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":"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":"SAST","score":7,"reason":"SAST tool detected but not run on all commits","details":["Info: SAST configuration detected: CodeQL","Warn: 0 commits out of 17 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"}}]},"last_synced_at":"2025-08-23T00:37:38.752Z","repository_id":45924535,"created_at":"2025-08-23T00:37:38.752Z","updated_at":"2025-08-23T00:37:38.752Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272636151,"owners_count":24967983,"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","status":"online","status_checked_at":"2025-08-29T02:00:10.610Z","response_time":87,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2025-08-29T05:36:37.628Z","updated_at":"2025-08-29T05:36:39.882Z","avatar_url":"https://github.com/react-component.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# rc-rate\n\nReact Rate Component\n\n[![NPM version][npm-image]][npm-url]\n[![npm download][download-image]][download-url]\n[![build status][github-actions-image]][github-actions-url]\n[![Codecov][codecov-image]][codecov-url]\n[![bundle size][bundlephobia-image]][bundlephobia-url]\n[![dumi][dumi-image]][dumi-url]\n\n[npm-image]: http://img.shields.io/npm/v/rc-rate.svg?style=flat-square\n[npm-url]: http://npmjs.org/package/rc-rate\n[github-actions-image]: https://github.com/react-component/rate/workflows/CI/badge.svg\n[github-actions-url]: https://github.com/react-component/rate/actions\n[codecov-image]: https://img.shields.io/codecov/c/github/react-component/rate/master.svg?style=flat-square\n[codecov-url]: https://codecov.io/gh/react-component/rate/branch/master\n[david-url]: https://david-dm.org/react-component/rate\n[david-image]: https://david-dm.org/react-component/rate/status.svg?style=flat-square\n[david-dev-url]: https://david-dm.org/react-component/rate?type=dev\n[david-dev-image]: https://david-dm.org/react-component/rate/dev-status.svg?style=flat-square\n[download-image]: https://img.shields.io/npm/dm/rc-rate.svg?style=flat-square\n[download-url]: https://npmjs.org/package/rc-rate\n[bundlephobia-url]: https://bundlephobia.com/result?p=rc-rate\n[bundlephobia-image]: https://badgen.net/bundlephobia/minzip/rc-rate\n[dumi-url]: https://github.com/umijs/dumi\n[dumi-image]: https://img.shields.io/badge/docs%20by-dumi-blue?style=flat-square\n\n## Screenshots\n\n\u003cimg src=\"https://img.alicdn.com/tps/TB1ijlpLVXXXXb8XpXXXXXXXXXX-466-172.png\" width=\"288\"/\u003e\n\n## Changelog\n\n- [CHANGELOG](./CHANGELOG.md)\n\n## Development\n\n```\nnpm install\nnpm start\n```\n\n## Example\n\n- Local: http://localhost:9001/\n\n- Online: http://react-component.github.io/rate/\n\n## install\n\n[![rc-rate](https://nodei.co/npm/rc-rate.png)](https://npmjs.org/package/rc-rate)\n\n## Usage\n\n```js\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport Rate from 'rc-rate';\n\nReactDOM.render(\n  \u003cRate /\u003e,\n  document.getElementById('root')\n)\n```\n\n### with [styled-components](https://github.com/styled-components/styled-components)\n```js\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport Rate from 'rc-rate';\nimport styled from 'styled-components';\n\nconst StyledRate = styled(Rate)`\n  \u0026.rc-rate {\n    font-size: ${({ size }) =\u003e size}px;\n  }\n`\n\nReactDOM.render(\n  \u003cStyledRate size=\"24\" /\u003e,\n  document.getElementById('root')\n)\n```\n\n## API\n\n### props\n\n| name          | type                              | default       | description                                           |\n| ------------- | --------------------------------- | ------------- | ----------------------------------------------------- |\n| count         | number                            | 5             | Star numbers                                          |\n| value         | number                            | -             | Controlled value                                      |\n| defaultValue  | number                            | 0             | Initial value                                         |\n| allowHalf     | boolean                           | false         | Support half star                                     |\n| allowClear    | boolean                           | true          | Reset when click again                                |\n| style         | object                            | {}            |                                                       |\n| onChange      | function                          | (value) =\u003e {} | `onChange` will be triggered when click               |\n| onHoverChange | function                          | (value) =\u003e {} | `onHoverChange` will be triggered when hover on stars |\n| character     | ReactNode \\| (props) =\u003e ReactNode | ★             | The each character of rate                            |\n| disabled      | boolean                           | false         |                                                       |\n| direction     | string                            | `ltr`         | The direction of rate                                 |\n\n## Test Case\n\n```\nnpm test\nnpm run chrome-test\n```\n\n## Coverage\n\n```\nnpm run coverage\n```\n\nopen coverage/ dir\n\n## License\n\nrc-rate is released under the MIT license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freact-component%2Frate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Freact-component%2Frate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freact-component%2Frate/lists"}