No More Posting New Topics!

If you have a question or an issue, please start a thread in our Github Discussions Forum.
This forum is closed for new threads/ topics.

Navigation

    Quasar Framework

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    How listener for Permissions change with capacitor

    Framework
    2
    2
    151
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • jonathan_on
      jonathan_on last edited by

      I need to watch when Permissions change, in case the user change the permission mannualy in configurations. In Capacitor documentation of Permissions is mencioned the method addListener, but with no examples or list of possible listeners:

      addListener(eventName: string, listenerFunc: Function): PluginListenerHandle
      

      I try various string in eventName, but no one works. Someone can help?

      metalsadman 1 Reply Last reply Reply Quote 0
      • metalsadman
        metalsadman @jonathan_on last edited by metalsadman

        @jonathan_on you cant listen to it if the user did it manually in the settings afaik (for security reasons), but you can check it within your app if you’re missing a permission, the way permission works now differently and it varies on the api lvl of your os. New ones now are shown on demand within the app and i think that’s how capacitor’s permission api works. So what you could do is just check it in your app and show a permission dialog for the ones that are not permitted yet, or check it on demand when the user goes to the page where your app needs permission.

        1 Reply Last reply Reply Quote 0
        • First post
          Last post