{"id":19053600,"url":"https://github.com/nating/react-native-custom-qr-codes","last_synced_at":"2025-04-09T23:17:28.678Z","repository":{"id":57336374,"uuid":"96535940","full_name":"nating/react-native-custom-qr-codes","owner":"nating","description":"Customisable QR codes for React Native","archived":false,"fork":false,"pushed_at":"2022-04-26T08:31:03.000Z","size":25706,"stargazers_count":97,"open_issues_count":14,"forks_count":47,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-04-09T23:17:00.326Z","etag":null,"topics":[],"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/nating.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}},"created_at":"2017-07-07T12:21:46.000Z","updated_at":"2024-12-23T14:51:19.000Z","dependencies_parsed_at":"2022-09-11T12:22:04.320Z","dependency_job_id":null,"html_url":"https://github.com/nating/react-native-custom-qr-codes","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nating%2Freact-native-custom-qr-codes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nating%2Freact-native-custom-qr-codes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nating%2Freact-native-custom-qr-codes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nating%2Freact-native-custom-qr-codes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nating","download_url":"https://codeload.github.com/nating/react-native-custom-qr-codes/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248125593,"owners_count":21051771,"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":[],"created_at":"2024-11-08T23:32:41.820Z","updated_at":"2025-04-09T23:17:28.518Z","avatar_url":"https://github.com/nating.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# react-native-custom-qr-codes\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"example-qr-code-1\" src=\"https://raw.githubusercontent.com/nating/react-native-custom-qr-codes/HEAD/assets/qr-code-1.png\" width=\"250\"\u003e\n  \u003cimg alt=\"example-qr-code-1\" src=\"https://raw.githubusercontent.com/nating/react-native-custom-qr-codes/HEAD/assets/qr-code-2.png\" width=\"250\"\u003e\n  \u003cimg alt=\"example-qr-code-3\" src=\"https://raw.githubusercontent.com/nating/react-native-custom-qr-codes/HEAD/assets/qr-code-3.png\" width=\"250\"\u003e\n\u003c/p\u003e\n\t\n\u003cp align=\"center\"\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  Customisable QR Codes for React Native.\n\u003c/p\u003e\n\n## Installation\n\n`npm install react-native-custom-qr-codes`\n\nIf you are not using Expo, you will also have to manually link the [react-native-svg library](https://github.com/react-native-community/react-native-svg).  \nFollow [the instructions here](https://github.com/react-native-community/react-native-svg#manual) to do this.\n\n## Usage\n\n\n```jsx\nimport { QRCode } from 'react-native-custom-qr-codes';\n\n\u003cQRCode content='https://reactnative.com'/\u003e\n```\n\n### Properties\n\n| Prop | Description | Default |\n|---|---|---|\n|**`content`**|The String to be encoded in the QR code. |`'No Content'`|\n|**`codeStyle`**|The style of the centre QR Code pieces. |`square`|\n|**`outerEyeStyle`**|The style of the outside of the QR Code's eyes. |`square`|\n|**`innerEyeStyle`**|The style of the inside of the QR Code's eyes. |`square`|\n|**`size`**|The width \u0026 height of the component. |`250`|\n|**`color`**|The color of the QR Code. |`black`|\n|**`backgroundColor`**|The background color of the component. |`white`|\n|**`padding`**|The padding between the edge of the component and the QR Code itself (In terms of QR code piece sizes). |`1`|\n|**`logo`**|The image to be put in the centre of the QR Code.\u003cbr\u003e**Must use a higher `ecl` for QR Code to work with a logo. \u003cbr\u003e(L-\u003eM-\u003eQ-\u003eH)** |none|\n|**`logoSize`**|The size of the logo in the QR Code. |none|\n|**`linearGradient`**|The two colors to be used for the linear gradient for the foreground. |none|\n|**`gradientDirection`**|The numbers that [define the orientation of the linear gradient](https://developer.mozilla.org/en-US/docs/Web/SVG/Tutorial/Gradients). |`[0,0,170,0]`|\n|**`backgroundImage`**|The image to be used as the filling of the QR Code pieces.\u003cbr\u003e**The Eyes can not be styled if a background image is used.**|none|\n|**`ecl`**|The [error correction level](http://www.qrcode.com/en/about/error_correction.html) of the QR Code. |`L`|\n\n## Examples\n\n### `codeStyle`\n```jsx\n\u003cQRCode codeStyle='square' /\u003e\n\u003cQRCode codeStyle='circle' /\u003e\n\u003cQRCode codeStyle='dot' /\u003e\n\u003cQRCode codeStyle='diamond' /\u003e\n\u003cQRCode codeStyle='sharp' /\u003e\n```\n\u003cimg src='./assets/example-code-styles.png' height='250'/\u003e\n\n### `outerEyeStyle`\n```jsx\n\u003cQRCode outerEyeStyle='square' /\u003e\n\u003cQRCode outerEyeStyle='circle' /\u003e\n\u003cQRCode outerEyeStyle='diamond' /\u003e\n```\n\u003cimg src='./assets/example-outer-eye-styles.png' height='250'/\u003e\n\n### `innerEyeStyle`\n```jsx\n\u003cQRCode innerEyeStyle='square' /\u003e\n\u003cQRCode innerEyeStyle='circle' /\u003e\n\u003cQRCode innerEyeStyle='diamond' /\u003e\n```\n\u003cimg src='./assets/example-inner-eye-styles.png' height='250'/\u003e\n\n### logo\n```jsx\n\u003cQRCode logo={require('./dab.png')} /\u003e\n```\n\u003cimg src='./assets/example-logo.png' height='250'/\u003e\n\n### linearGradient\n```jsx\n\u003cQRCode linearGradient={['rgb(255,0,0)','rgb(0,255,255)']} /\u003e\n\u003cQRCode linearGradient={['rgb(255,0,0)','rgb(0,255,255)']} gradientDirection={[0,170,0,0]} /\u003e\n```\n\u003cimg src='./assets/example-linear-gradient.png' height='250'/\u003e\n\n### backgroundImage\n```jsx\n\u003cQRCode backgroundImage={require('./galaxy.png')} /\u003e\n```\n\u003cimg src='./assets/example-background-image.png' height='250'/\u003e\n\n## Contributing\n\nTake a look at [CONTRIBUTING.md](./CONTRIBUTING.md) 😁\n\n## License\n\n[MIT License](http://opensource.org/licenses/mit-license.html). © Geoffrey Natin 2017\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnating%2Freact-native-custom-qr-codes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnating%2Freact-native-custom-qr-codes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnating%2Freact-native-custom-qr-codes/lists"}