{"id":30654058,"url":"https://github.com/mthahzan/react-native-image-fallback","last_synced_at":"2025-08-31T08:13:54.730Z","repository":{"id":21582509,"uuid":"93007527","full_name":"mthahzan/react-native-image-fallback","owner":"mthahzan","description":"Image loader component with fallbacks for React Native apps","archived":false,"fork":false,"pushed_at":"2025-07-22T07:06:59.000Z","size":2217,"stargazers_count":38,"open_issues_count":2,"forks_count":5,"subscribers_count":3,"default_branch":"development","last_synced_at":"2025-08-14T18:54:33.066Z","etag":null,"topics":["fallback","react-native"],"latest_commit_sha":null,"homepage":"","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/mthahzan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","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,"zenodo":null}},"created_at":"2017-06-01T02:20:36.000Z","updated_at":"2025-05-01T03:25:56.000Z","dependencies_parsed_at":"2025-05-01T04:32:08.490Z","dependency_job_id":null,"html_url":"https://github.com/mthahzan/react-native-image-fallback","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/mthahzan/react-native-image-fallback","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mthahzan%2Freact-native-image-fallback","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mthahzan%2Freact-native-image-fallback/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mthahzan%2Freact-native-image-fallback/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mthahzan%2Freact-native-image-fallback/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mthahzan","download_url":"https://codeload.github.com/mthahzan/react-native-image-fallback/tar.gz/refs/heads/development","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mthahzan%2Freact-native-image-fallback/sbom","scorecard":{"id":666528,"data":{"date":"2025-08-11","repo":{"name":"github.com/mthahzan/react-native-image-fallback","commit":"d6fd6475d9cf01ff0caa24eab0ed34c21e66ca5f"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.8,"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":"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":"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/7 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":"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":"Token-Permissions","score":9,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Info: topLevel 'contents' permission set to 'read': .github/workflows/pr-check.yml:11","Warn: topLevel 'checks' permission set to 'write': .github/workflows/pr-check.yml:12","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":"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":"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":"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":"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/pr-check.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:28: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:36: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:45: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:59: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:65: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:71: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:77: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:90: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:96: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:102: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:108: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/pr-check.yml:116: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/pr-check.yml:124: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:135: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:141: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:147: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pr-check.yml:153: update your workflow using https://app.stepsecurity.io/secureworkflow/mthahzan/react-native-image-fallback/pr-check.yml/development?enable=pin","Info:   0 out of  16 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   2 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":"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":1,"reason":"branch protection is not maximal on development and all release branches","details":["Warn: branch protection not enabled for branch 'development'","Info: 'allow deletion' disabled on branch 'master'","Info: 'force pushes' disabled on branch 'master'","Warn: 'branch protection settings apply to administrators' is disabled on branch 'master'","Warn: 'stale review dismissal' is disabled on branch 'master'","Warn: branch 'master' does not require approvers","Warn: codeowners review is not required on branch 'master'","Warn: 'last push approval' is disabled on branch 'master'","Warn: no status checks found to merge onto branch 'master'","Info: PRs are required in order to make changes on 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":6,"reason":"SAST tool is not run on all commits -- score normalized to 6","details":["Warn: 17 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"}},{"name":"Vulnerabilities","score":0,"reason":"19 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-x4c5-c7rf-jjgv","Warn: Project is vulnerable to: GHSA-h5c3-5r3r-rr8q","Warn: Project is vulnerable to: GHSA-rmvr-2pp2-xj38","Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-m5qc-5hw7-8vg7","Warn: Project is vulnerable to: GHSA-p6mc-m468-83gw","Warn: Project is vulnerable to: GHSA-29mw-wpgm-hmr9","Warn: Project is vulnerable to: GHSA-35jh-r3h4-6jhm","Warn: Project is vulnerable to: GHSA-76c9-3jph-rj3q","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6","Warn: Project is vulnerable to: GHSA-jgrx-mgxx-jf9v","Warn: Project is vulnerable to: GHSA-cxrh-j4jr-qwg3","Warn: Project is vulnerable to: GHSA-6fc8-4gx4-v693","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-21T18:13:13.110Z","repository_id":21582509,"created_at":"2025-08-21T18:13:13.111Z","updated_at":"2025-08-21T18:13:13.111Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272953955,"owners_count":25021136,"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-31T02:00:09.071Z","response_time":79,"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":["fallback","react-native"],"created_at":"2025-08-31T08:13:54.150Z","updated_at":"2025-08-31T08:13:54.717Z","avatar_url":"https://github.com/mthahzan.png","language":"TypeScript","readme":"# React Native Image Fallback\n\n## Table of Contents\n\n1. [Introduction](#introduction)\n2. [Getting Started](#getting-started)\n3. [Usage](#usage)\n4. [Properties](#properties)\n5. [Using a Custom Component](#using-a-custom-component)\n\n## Introduction\n\nReact Native Image Fallback is a lightweight image component that supports fallback images for React Native apps. It is a drop-in replacement for the React Native Image component with the added feature of fallback images. This is useful when you want to display a placeholder image when the main image fails to load.\n\n## Getting Started\n\n### Installation\n\n```bash\n# Using npm\nnpm install react-native-image-fallback --save\n\n# Using Yarn\nyarn add react-native-image-fallback\n```\n\n## Usage\n\n```jsx\nimport Image from 'react-native-image-fallback';\n\nconst IMAGE_URL = {uri: 'http://image.url'};\nconst FALLBACKS = [\n  {uri: 'http://another.image.url'},\n  require('./local/image/path'),\n];\n\nconst App = () =\u003e \u003cImage source={IMAGE_URL} fallback={FALLBACKS} /\u003e;\n```\n\n## Properties\n\n`Image` extends the React Native `Image` component, so all the `\u003cImage /\u003e` props will work. In addition, it supports the following props:\n\n| Prop        | Type                             | Description                                                      |\n| ----------- | -------------------------------- | ---------------------------------------------------------------- |\n| `source`    | [`TImageSource`](#timagesource)  | The source image (**REQUIRED**)                                  |\n| `fallback`  | `TImageSource \\| TImageSource[]` | The fallback image(s). Can be a single item or an array          |\n| `component` | Component                        | Alternative component to use. Default: `Image` from React Native |\n\n### TImageSource\n\n`TImageSource` is a type that can be a `require('')` image file, or an [image source](https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Image/ImageSource.js) object.\n\n### `fallback`\n\nThe `fallback` prop can be a single image source or an array of image sources. If the main image fails to load, the fallback image(s) will be used instead. The fallback images are used in the order they are provided.\n\n**Note**: If an array of fallbacks is provided, the library relies on a stable reference to the array. If the reference changes, the fallback logic will reset and start over.\n\n## Using a Custom Component\n\nAny component that has the same props as the React Native `Image` component can be used as a custom component. This is useful when you want to use a custom image component that has additional features or styling. For example, you can easily use a more performant image component like `FastImage` as a fallback.\n\n```jsx\nimport FastImage from 'react-native-fast-image';\nimport Image from 'react-native-image-fallback';\n\n\u003cImage component={FastImage} source={imageSource} fallback={fallbacks} /\u003e;\n```\n\n## Contributing\n\nPlease read [CONTRIBUTING.md](CONTRIBUTING.md) for details on our code of conduct, and the process for submitting pull requests to us.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmthahzan%2Freact-native-image-fallback","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmthahzan%2Freact-native-image-fallback","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmthahzan%2Freact-native-image-fallback/lists"}