react-native-send-intent
react-native-send-intent copied to clipboard
feat(add-open-settings-uri-context)
- support passing uri into the openSettings so menus such as file manager permissions can open with the settings intent
- add uri option parameter to all sections of the app.
- default uri to null if not provided by the API and pass the null value to the native side.
Questions:
- Is there a way to test these changes? I'm not able to build the gradle project.
- Can we add documentation for how to build this repo?
Edit:
- I tested this in my own repo doing install like so
"react-native-send-intent": "git+https://github.com/FrederickEngelhardt/react-native-send-intent/#feat/add-open-settings-uri-context". FYI with this method cache is nasty. Run this if you need to make updatesyarn cache clean react-native-send-intent. Symlinks can also work but they require metro workarounds.
I tested this and links work well. So I think this feature is stable. Without the URI nothing will navigate but that's fine.
Example code
const uri = `package:<package.name>` // must be your test app's package that requires this permission
openSettings('android.settings.MANAGE_APP_ALL_FILES_ACCESS_PERMISSION', uri)
Hi @FrederickEngelhardt this looks pretty cool ;)
Hi @FrederickEngelhardt this looks pretty cool ;)
Hi @FrederickEngelhardt this looks pretty cool ;)
@lucasferreira Just following up.
Does this change seem acceptable. If so, can we merge this PR?