React Native: Native Easy Permissions
ReactNative: Native Easy Permissions Library (Android/iOS)
If this project has helped you out, please support us with a star π
This library is a React Native bridge around native library providing Dialog for permissions.
iOS: ivanvorobei/SPPermissions |
---|
Android: Facebook/ReactNative.PermissionsAndroid |
---|
This library is support RN61+
$ npm install react-native-easy-permissions --save
iOS Prerequisite: Please make sure
CocoaPods
is installed on your system
- Add the following to your `Podfile` -> `ios/Podfile` and run pod update:
use_native_modules!
pod 'RNEasyPermissions', :path => '../node_modules/react-native-easy-permissions/ios'
use_frameworks!
pod 'SPPermissions', :git => 'https://github.com/prscX/SPPermissions', :branch => 'react-native'
No configuration is required
import { RNEasyPermissions } from 'react-native-easy-permissions'
RNEasyPermissions.Show({
// iOS Permissions
permissions: ['Camera', 'Contacts', 'Calendar', 'PhotoLibrary', 'Notification', 'Microphone', 'Reminders', 'SpeechRecognizer', 'Location', 'Motion', 'MediaLibrary', 'Bluetooth']
// Android Permissions
// permissions: [
// 'android.permission-group.CALENDAR',
// 'android.permission-group.CAMERA',
// 'android.permission-group.LOCATION',
// 'android.permission.READ_SMS',
// 'android.permission.ACCESS_FINE_LOCATION'
// ]
});
Prop | Type | Default | Note |
---|---|---|---|
Show({ permissions: [] }) |
func |
It invoke native permissions dialog |
Have an idea? Found a bug? Please raise to ISSUES.
Contributions are welcome and are greatly appreciated! Every little bit helps, and credit will always be given.
If you are using this library in one of your projects, add it in this list below. β¨
This library is provided under the Apache 2 License.
RNAppTour @ prscX
I open-source almost everything I can, and I try to reply everyone needing help using these projects. Obviously, this takes time. You can integrate and use these projects in your applications for free! You can even change the source code and redistribute (even resell it).
However, if you get some profit from this or just want to encourage me to continue creating stuff, there are few ways you can do it:
Starring and sharing the projects you like π
If youβre feeling especially charitable, please follow prscX on GitHub.
Thanks! β€οΈ
prscX.github.io
</ Pranav >