{"id":18487143,"url":"https://github.com/nihgwu/react-native-pie","last_synced_at":"2025-10-10T20:34:00.446Z","repository":{"id":57339095,"uuid":"82812725","full_name":"nihgwu/react-native-pie","owner":"nihgwu","description":"Pie chart for React Native","archived":false,"fork":false,"pushed_at":"2020-09-07T19:39:32.000Z","size":474,"stargazers_count":107,"open_issues_count":16,"forks_count":27,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-09-28T09:29:37.732Z","etag":null,"topics":["chart","doughnut","gauge","pie-chart","react-native","svg"],"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/nihgwu.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":"2017-02-22T14:19:20.000Z","updated_at":"2024-06-12T13:29:10.000Z","dependencies_parsed_at":"2022-08-28T10:00:12.532Z","dependency_job_id":null,"html_url":"https://github.com/nihgwu/react-native-pie","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/nihgwu/react-native-pie","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nihgwu%2Freact-native-pie","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nihgwu%2Freact-native-pie/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nihgwu%2Freact-native-pie/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nihgwu%2Freact-native-pie/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nihgwu","download_url":"https://codeload.github.com/nihgwu/react-native-pie/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nihgwu%2Freact-native-pie/sbom","scorecard":{"id":686889,"data":{"date":"2025-08-11","repo":{"name":"github.com/nihgwu/react-native-pie","commit":"0687c2a8b49faca05bc0dbeadb55909d7b7af17f"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.8,"checks":[{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","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":"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":"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":6,"reason":"Found 7/11 approved changesets -- score normalized to 6","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":-1,"reason":"No tokens found","details":null,"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":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"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":"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: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 26 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-22T01:10:33.896Z","repository_id":57339095,"created_at":"2025-08-22T01:10:33.897Z","updated_at":"2025-08-22T01:10:33.897Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279005272,"owners_count":26083863,"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-10-10T02:00:06.843Z","response_time":62,"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":["chart","doughnut","gauge","pie-chart","react-native","svg"],"created_at":"2024-11-06T12:50:15.058Z","updated_at":"2025-10-10T20:34:00.423Z","avatar_url":"https://github.com/nihgwu.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# react-native-pie\n\nPie chart for React Native, works on both **iOS** and **Android**\n\n## Demo\n\n![iOS](demo/ios.png)\n![Android](demo/android.png)\n\n## Install\n\n```bash\n# NPM\nnpm i --save react-native-pie\nOR\n# Yarn\nyarn add react-native-pie\n```\n\n## For react-native-pie \u003e= 1.1.0 install peer dependency\n```bash\n# NPM\nnpm i --save @react-native-community/art\nOR\n# Yarn\nyarn add @react-native-community/art\n```\n\n## Migration from react-native-pie \u003c= 0.6.2\n\nPlease unlink react-native ART library\n\n## Linking module\n\n### Mostly automatic linking\n\nIf `react-native` \u003e= 0.60 \u0026\u0026 react-native-pie \u003e= 1.1.0, the package will be linked automatically.\n\n### Manual linking for react-native-pie \u003c= 0.6.2\nLink the ART library to your ReactNative project ([how to link a library](https://facebook.github.io/react-native/docs/linking-libraries-ios.html#content)). You'll find the React ART library in `node_modules/react-native/Libraries/ART/ART.xcodeproj`\n\n\n### React Native Version Support\n\u003e **If you are using \u003c `.45`, please install `react-native-pie` `v0.1.0` instead**   \n\u003e `npm i --save react-native-pie@0.1.0`\n\n\u003e **Please use \u003e= `0.50.0-rc.0` otherwise there is a ring shape drawing issue with `react-native-pie`**\n\n## Usage\n\n```jsx\nimport React from 'react'\nimport {\n  StyleSheet,\n  View,\n  Text,\n} from 'react-native'\nimport Pie from 'react-native-pie'\n\nexport default () =\u003e {\n    return (\n      \u003cView style={styles.container}\u003e\n          \u003cView\n            style={{\n              paddingVertical: 15,\n              flexDirection: 'row',\n              width: 350,\n              justifyContent: 'space-between',\n            }}\n          \u003e\n            \u003cPie\n              radius={80}\n              sections={[\n                {\n                  percentage: 10,\n                  color: '#C70039',\n                },\n                {\n                  percentage: 20,\n                  color: '#44CD40',\n                },\n                {\n                  percentage: 30,\n                  color: '#404FCD',\n                },\n                {\n                  percentage: 40,\n                  color: '#EBD22F',\n                },\n              ]}\n              strokeCap={'butt'}\n            /\u003e\n            \u003cPie\n              radius={80}\n              innerRadius={50}\n              sections={[\n                {\n                  percentage: 10,\n                  color: '#C70039',\n                },\n                {\n                  percentage: 20,\n                  color: '#44CD40',\n                },\n                {\n                  percentage: 30,\n                  color: '#404FCD',\n                },\n                {\n                  percentage: 40,\n                  color: '#EBD22F',\n                },\n              ]}\n              strokeCap={'butt'}\n            /\u003e\n          \u003c/View\u003e\n          \u003cView\n            style={{\n              paddingVertical: 15,\n              flexDirection: 'row',\n              width: 350,\n              justifyContent: 'space-between',\n            }}\n          \u003e\n            \u003cPie\n              radius={80}\n              innerRadius={60}\n              sections={[\n                {\n                  percentage: 10,\n                  color: '#C70039',\n                },\n                {\n                  percentage: 20,\n                  color: '#44CD40',\n                },\n                {\n                  percentage: 30,\n                  color: '#404FCD',\n                },\n                {\n                  percentage: 40,\n                  color: '#EBD22F',\n                },\n              ]}\n              dividerSize={4}\n              strokeCap={'round'}\n            /\u003e\n            \u003cPie\n              radius={80}\n              innerRadius={60}\n              sections={[\n                {\n                  percentage: 10,\n                  color: '#C70039',\n                },\n                {\n                  percentage: 20,\n                  color: '#44CD40',\n                },\n                {\n                  percentage: 30,\n                  color: '#404FCD',\n                },\n                {\n                  percentage: 40,\n                  color: '#EBD22F',\n                },\n              ]}\n              dividerSize={6}\n              strokeCap={'butt'}\n            /\u003e\n          \u003c/View\u003e\n          \u003cView\n            style={{\n              paddingVertical: 15,\n              width: 350,\n              flexDirection: 'row',\n              justifyContent: 'space-between',\n            }}\n          \u003e\n            \u003cPie\n              radius={80}\n              sections={[\n                {\n                  percentage: 10,\n                  color: '#C70039',\n                },\n                {\n                  percentage: 20,\n                  color: '#44CD40',\n                },\n                {\n                  percentage: 30,\n                  color: '#404FCD',\n                },\n                {\n                  percentage: 40,\n                  color: '#EBD22F',\n                },\n              ]}\n              dividerSize={6}\n              strokeCap={'butt'}\n            /\u003e\n            \u003cView style={{ width: 175, alignItems: 'center' }}\u003e\n              \u003cPie\n                radius={80}\n                innerRadius={75}\n                sections={[\n                  {\n                    percentage: 60,\n                    color: '#f00',\n                  },\n                ]}\n                backgroundColor=\"#ddd\"\n              /\u003e\n              \u003cView\n                style={styles.gauge}\n              \u003e\n                \u003cText\n                  style={styles.gaugeText}\n                \u003e\n                  60%\n                \u003c/Text\u003e\n              \u003c/View\u003e\n            \u003c/View\u003e\n          \u003c/View\u003e\n        \u003c/View\u003e\n    )\n  \n}\n\nconst styles = StyleSheet.create({\n  container: { alignItems: 'center', justifyContent: 'center', height: 1050 },\n  gauge: {\n    position: 'absolute',\n    width: 100,\n    height: 160,\n    alignItems: 'center',\n    justifyContent: 'center',\n  },\n  gaugeText: {\n    backgroundColor: 'transparent',\n    color: '#000',\n    fontSize: 24,\n  },\n})\n```\n\n## Props\n\n* **sections** `{percentage, color}` of each section in the pie - array, **required**\n* **radius** `radius = size / 2` , - number, **required**\n* **innerRadius** defaults to `0` - number, **optional**\n* **backgroundColor** defaults to `#fff` - string, **optional**\n* **strokeCap** ( `round` , `butt` ) defaults to `butt` - string, **optional**\n  * **PLEASE NOTE** If using `strokeCap={'round'}` it is highly recommended to use a higher `innerRadius` (around 60% of `radius` and higher) in addition to not having very small percentage sections. This will ensure proper display. We hope to address these issues in future PRs\n* **dividerSize** defaults to `0` - percentage size to divide the sections - number, **optional**\n\n## License\n\nMIT\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnihgwu%2Freact-native-pie","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnihgwu%2Freact-native-pie","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnihgwu%2Freact-native-pie/lists"}