Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/renanmav/react-native-in-app-browser
🌐 In-app-browser (IAB) native bindings for react-native
https://github.com/renanmav/react-native-in-app-browser
Last synced: about 1 month ago
JSON representation
🌐 In-app-browser (IAB) native bindings for react-native
- Host: GitHub
- URL: https://github.com/renanmav/react-native-in-app-browser
- Owner: renanmav
- License: mit
- Created: 2024-10-15T00:47:20.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2024-11-10T20:36:23.000Z (about 2 months ago)
- Last Synced: 2024-11-10T21:36:25.643Z (about 2 months ago)
- Language: C++
- Homepage:
- Size: 1 MB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# react-native-in-app-browser
An in-app-browser (IAB) module for react-native exposing bindings for [SFSafariViewController](https://developer.apple.com/documentation/safariservices/sfsafariviewcontroller), [ASWebAuthenticationSession](https://developer.apple.com/documentation/authenticationservices/aswebauthenticationsession), [ChromeCustomTabs](https://developer.chrome.com/docs/android/custom-tabs) & more, powered by [Nitro Modules](https://nitro.margelo.com).
## Features
- Easy-to-use API
- Common cross-platform support
- Platform-specific implementations (iOS and Android)## Installation
> [!IMPORTANT]
> Make sure you add [react-native-nitro-modules](https://github.com/mrousavy/nitro) as dependency.```bash
npx install @renanmav/react-native-in-app-browser
```## Usage
You can choose between common or platform-specific interfacing.
### Basic usage
```typescript
import { InAppBrowser } from 'react-native-in-app-browser'
// Open a URL in the in-app browser
InAppBrowser.open('https://example.com')
```## Platform Compatibility
| Feature | iOS | Android |
| -------------------------- | --- | ------- |
| InAppBrowser | ✅ | ✅ |
| SFSafariViewController | ✅ | ❌ |
| ASWebAuthenticationSession | ✅ | ❌ |
| ChromeCustomTabs | ❌ | ✅ |## Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.