Re: [screen-wake-lock] Should we modify Permission prompt text? (#324)

> One thing to add though: Are we not considering using Permissions Policy to control this? That is, might sites want to prevent nested browsing contexts accessing the feature? That might suggest that there is still some value in the integration.

Yes, it's a policy controlled feature. 

But even in that case, the Permissions Policy's API is the appropriate way to query this: 

```JS
document.permissionsPolicy.allowsFeature("web-share");
```

For policy controlled features, `navigator.permission.query()` only comes into play for UI-based features, whereby `.query()` always returns "denied". It doesn't do anything else that is helpful or meaningful. 

-- 
GitHub Notification of comment by marcoscaceres
Please view or discuss this issue at https://github.com/w3c/screen-wake-lock/issues/324#issuecomment-906922796 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Friday, 27 August 2021 04:49:32 UTC