{"id":4027,"url":"https://github.com/huiseoul/react-native-fit-image","last_synced_at":"2025-06-13T23:02:29.816Z","repository":{"id":46939117,"uuid":"56836509","full_name":"huiseoul/react-native-fit-image","owner":"huiseoul","description":"Responsive image component to fit perfectly itself.","archived":false,"fork":false,"pushed_at":"2021-09-21T01:42:21.000Z","size":7159,"stargazers_count":583,"open_issues_count":13,"forks_count":54,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-05-11T14:23:49.674Z","etag":null,"topics":["android","component","fit","image","ios","react-native","responsive"],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/huiseoul.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":"2016-04-22T07:43:12.000Z","updated_at":"2025-01-30T15:00:35.000Z","dependencies_parsed_at":"2022-09-26T21:40:13.898Z","dependency_job_id":null,"html_url":"https://github.com/huiseoul/react-native-fit-image","commit_stats":null,"previous_names":[],"tags_count":22,"template":false,"template_full_name":null,"purl":"pkg:github/huiseoul/react-native-fit-image","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/huiseoul%2Freact-native-fit-image","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/huiseoul%2Freact-native-fit-image/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/huiseoul%2Freact-native-fit-image/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/huiseoul%2Freact-native-fit-image/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/huiseoul","download_url":"https://codeload.github.com/huiseoul/react-native-fit-image/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/huiseoul%2Freact-native-fit-image/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259732706,"owners_count":22903084,"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","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":["android","component","fit","image","ios","react-native","responsive"],"created_at":"2024-01-05T20:16:58.889Z","updated_at":"2025-06-13T23:02:29.718Z","avatar_url":"https://github.com/huiseoul.png","language":"TypeScript","funding_links":[],"categories":["Components","Others"],"sub_categories":["UI"],"readme":"# React Native Fit Image [![npm version](https://badge.fury.io/js/react-native-fit-image.svg)](https://badge.fury.io/js/react-native-fit-image)\nReact Native Fit Image enables you to draw responsive image component.\n\n## Introduction\nResponsive image component to fit perfectly itself.\n\n## Install\n`npm install react-native-fit-image --save`\n\n## Usage\n```javascript\nimport FitImage from 'react-native-fit-image';\n\n// custom styles for FitImage\nvar styles = StyleSheet.create({\n  fitImage: {\n    borderRadius: 20,\n  },\n  fitImageWithSize: {\n    height: 100,\n    width: 30,\n  },\n});\n\n// draws image to fit inherited space automatically, even when screen is rotated.\n// even you don't need to provide original size in v1.2.0\n\u003cFitImage\n  source={{ uri: 'https://facebook.github.io/react-native/docs/assets/favicon.png' }}\n  style={styles.fitImage}\n/\u003e\n\n// draws image to fit inherited space automatically and disables loading indicator\n\u003cFitImage\n  indicator={false} // disable loading indicator\n  indicatorColor=\"white\" // react native colors or color codes like #919191\n  indicatorSize=\"large\" // (small | large) or integer\n  source={{ uri: 'https://facebook.github.io/react-native/docs/assets/favicon.png' }}\n  style={styles.fitImage}\n/\u003e\n\n// draws image to fit inherited space automatically, even when screen is rotated.\n\u003cFitImage\n  source={{ uri: 'https://facebook.github.io/react-native/docs/assets/favicon.png' }}\n  originalWidth={400}\n  originalHeight={400}\n  style={styles.fitImage}\n/\u003e\n\n// could use resizeMode\n\u003cFitImage\n  resizeMode=\"contain\"\n  source={{ uri: 'https://facebook.github.io/react-native/docs/assets/favicon.png' }}\n/\u003e\n\n// or draws image to specific size like Image component.\n\u003cFitImage\n  source={{ uri: 'https://facebook.github.io/react-native/docs/assets/favicon.png' }}\n  style={styles.fitImageWithSize}\n/\u003e\n\n// draws local image (currently, it does not support responsive)\n\u003cFitImage\n  source={require('fit-image.png')}\n  style={styles.fitImageWithSize}\n/\u003e\n```\n\n## Example\n- See a [FitImageExample][1].\n\n![FitImageExample - Portrait](https://github.com/originerd/react-native-fit-image-example/raw/master/fit_image_example_portrait.gif)\n![FitImageExample - LandScape](https://github.com/originerd/react-native-fit-image-example/raw/master/fit_image_example_landscape.gif)\n\n[1]: https://github.com/originerd/react-native-fit-image-example\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhuiseoul%2Freact-native-fit-image","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhuiseoul%2Freact-native-fit-image","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhuiseoul%2Freact-native-fit-image/lists"}