{"id":27610653,"url":"https://github.com/callstackincubator/react-native-legal","last_synced_at":"2025-05-16T17:03:42.160Z","repository":{"id":190678705,"uuid":"675626690","full_name":"callstackincubator/react-native-legal","owner":"callstackincubator","description":"Automagically generate license acknowledgements for your React Native app","archived":false,"fork":false,"pushed_at":"2025-05-07T09:02:49.000Z","size":38757,"stargazers_count":196,"open_issues_count":8,"forks_count":3,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-05-07T10:23:07.680Z","etag":null,"topics":["acknowledgements","android","ios","licenses","react-native","tvos"],"latest_commit_sha":null,"homepage":"https://callstackincubator.github.io/react-native-legal/","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/callstackincubator.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":"2023-08-07T11:01:51.000Z","updated_at":"2025-05-07T09:02:53.000Z","dependencies_parsed_at":null,"dependency_job_id":"a055c65e-0ffc-43ef-bcb4-720c0c33c85a","html_url":"https://github.com/callstackincubator/react-native-legal","commit_stats":null,"previous_names":["callstack-internal/with-react-native-oss-notice","callstackincubator/react-native-legal"],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/callstackincubator%2Freact-native-legal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/callstackincubator%2Freact-native-legal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/callstackincubator%2Freact-native-legal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/callstackincubator%2Freact-native-legal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/callstackincubator","download_url":"https://codeload.github.com/callstackincubator/react-native-legal/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253958045,"owners_count":21990548,"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":["acknowledgements","android","ios","licenses","react-native","tvos"],"created_at":"2025-04-22T23:29:57.370Z","updated_at":"2025-05-16T17:03:42.131Z","avatar_url":"https://github.com/callstackincubator.png","language":"TypeScript","funding_links":[],"categories":["TypeScript"],"sub_categories":[],"readme":"# `react-native-legal`\n\nAutomagically generate license acknowledgements for your React Native app 🚀\n\n| Android | iOS | AndroidTV | tvOS |\n| - | - | - | - |\n| ![Android example](https://github.com/callstackincubator/react-native-legal/raw/main/static/android-expo.gif) | ![iOS example](https://github.com/callstackincubator/react-native-legal/raw/main/static/ios-expo.gif) | ![AndroidTV example](https://github.com/callstackincubator/react-native-legal/raw/main/static/android-tv.gif) | ![tvOS example](https://github.com/callstackincubator/react-native-legal/raw/main/static/tvos.gif) |\n\n## Installation\n\n```sh\nyarn add react-native-legal\n```\n\nor\n\n```sh\nnpm i --save react-native-legal\n```\n\n## Usage\n\nThis tool is split into 2 parts:\n- a library that lets you display native screen with a list of all dependencies and their licenses\n- a [config plugin](https://docs.expo.dev/config-plugins/introduction/?redirected) (for Expo projects) and a [custom community cli plugin](https://github.com/react-native-community/cli/blob/main/docs/plugins.md) (for bare RN projects)\n\n### I want to generate licenses in my Expo project \u003ca name=\"usage-expo\"\u003e\u003c/a\u003e\n\n1. Add the config plugin to the `app.json`/`app.config.js`\n\n```diff\n{\n  \"expo\": {\n    \"plugins\": [\n+      \"react-native-legal\"\n    ]\n  }\n}\n```\n\n2. Use the library in the codebase\n\n```tsx\nimport * as React from 'react';\nimport { Button, View } from 'react-native';\nimport { ReactNativeLegal } from 'react-native-legal';\n\nfunction launchNotice() {\n  ReactNativeLegal.launchLicenseListScreen('OSS Notice');\n}\n\nfunction MyComponent() {\n  return (\n    \u003cView\u003e\n      \u003cButton onPress={launchNotice} text=\"Open source licenses\" /\u003e\n    \u003c/View\u003e\n  );\n}\n```\n\n3. Use [Prebuild](https://docs.expo.dev/workflow/prebuild/) or [EAS](https://docs.expo.dev/eas/) to build the app\n\n### I want to generate licenses in my bare RN project \u003ca name=\"usage-bare-rn\"\u003e\u003c/a\u003e\n\n1. Invoke the CLI plugin from the root of your RN app\n\n```sh\nnpx react-native legal-generate\n```\n\nor\n\n```sh\nyarn react-native legal-generate\n```\n\n2. Use the library in the codebase\n\n```tsx\nimport * as React from 'react';\nimport { Button, View } from 'react-native';\nimport { ReactNativeLegal } from 'react-native-legal';\n\nfunction launchNotice() {\n  ReactNativeLegal.launchLicenseListScreen('OSS Notice');\n}\n\nfunction MyComponent() {\n  return (\n    \u003cView\u003e\n      \u003cButton onPress={launchNotice} text=\"Open source licenses\" /\u003e\n    \u003c/View\u003e\n  );\n}\n```\n\n## Expo\n\n- ✅ You can use this library with [Development Builds](https://docs.expo.dev/development/introduction/) by adding `react-native-legal` to your `app.json`/`app.config.js` plugins array.\n- ❌ This library can't be used in the \"Expo Go\" app because it [requires custom native code](https://docs.expo.dev/workflow/customizing/).\n\n## Contributing\n\nSee the [contributing guide](./CONTRIBUTING) to learn how to contribute to the repository and the development workflow.\n\n## Acknowledgements\n\n- [AboutLibraries](https://github.com/mikepenz/AboutLibraries) - collects and displays the license metadata for the Android app \u003c3\n- [LicensePlist](https://github.com/mono0926/LicensePlist) - generates license metadata for the iOS app \u003c3\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcallstackincubator%2Freact-native-legal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcallstackincubator%2Freact-native-legal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcallstackincubator%2Freact-native-legal/lists"}