Languages
[Edit]
EN

JavaScript - list of all navigator permissions query status states

0 points
Created by:
Imaan-Morin
1009

In this article, we would like to show you list of all navigator permissions query status state values with explanation in JavaScript.

Quick solution:

  • 'granted'
  • 'prompt'
  • 'denied'

 

1. Status value: granted

Edit

The 'granted' status value, means that the user, or the user agent on the user's behalf, has given permission to use the API. The caller can now use the feature (like microphone, camera, etc.) possibly without having the user agent asking the user's permission.

2. Status value: prompt

Edit

The 'prompt' status value, means that the user has not given permission to use the API (it's the same as denied). It also means that if a caller attempts to use the feature (like microphone, camera, etc.), the user agent will either be prompting the user for permission or access to the feature will be denied.

3. Status value: denied

Edit

The 'denied' status value, means that the user, or the user agent on the user's behalf, has denied access to the API. The caller will can't use the feature (microphone, camera, etc.).

 

References

Edit
  1. PermissionStatus - Web APIs | MDN
  2. PermissionStatus.state - Web APIs | MDN

Alternative titles

  1. JavaScript - navigator permissions query status state values list with explanation
1
Donate to Dirask
Our content is created by volunteers - like Wikipedia. If you think, the things we do are good, donate us. Thanks!
Join to our subscribers to be up to date with content, news and offers.
Native Advertising
🚀
Get your tech brand or product in front of software developers.
For more information Contact us
Dirask - we help you to
solve coding problems.
Ask question.

❤️💻 🙂

Join