Hey guys, I want request a permission and I am loo...
# compose
k
Hey guys, I want request a permission and I am looking in this stack overflow. Inside this question there is two answer which I am getting confused. First one is using Activity-compose and another is using Google Accompanist's Jetpack Compose Permissions. So which one is recommended way of doing? Can someone guide me on this. Many Thanks
a
In terms of implementation, both will end up doing the same thing: using the activity launcher APIs to request permission, and using the permissions APIs to check the status. accompanist/permissions just wraps those underlying calls into a nicer, more easy-to-use interface. So using accompanist/permissions should make it easier to get started, but it’s not doing anything magical or something you couldn’t do yourself with the underlying APIs.
k
Sure then I'll work with accompanist api. I really appreciate your feedback.
a
No problem! I’d also recommend https://medium.com/androiddevelopers/jetpack-compose-accompanist-an-faq-b55117b02712 for an overview of what Accompanist is, and it’s overall role as a set of libraries.
k
Thank you so much