Update Feature-Policy to Permissions-Policy#22439
Conversation
4bfa476 to
58ac7be
Compare
|
This pull request has merge conflicts that must be resolved before it can be merged. |
| To use this sensor, the user must grant permission to the `'accelerometer'`, `'gyroscope'`, and `'magnetometer'` device sensors through the [Permissions API](/en-US/docs/Web/API/Permissions_API). | ||
|
|
||
| If a feature policy blocks use of a feature it is because your code is inconsistent with the policies set on your server. This is not something that would ever be shown to a user. The {{httpheader('Feature-Policy')}} HTTP header article contains implementation instructions. | ||
| If a Permissions Policy blocks use of a feature it is because your code is inconsistent with the policies set on your server. This is not something that would ever be shown to a user. Our [Permissions Policy](/en-US/docs/Web/HTTP/Permissions_Policy) article contains implementation instructions. |
There was a problem hiding this comment.
So, FWIW, I do not like this note, because I don't know what ". This is not something that would ever be shown to a user." means/the intent.
It is worth saying that this might be blocked though and rolling out everywhere. Something like:
This feature may be blocked by a server Permissions Policy.
... unless there is a nuance I am missing that needs to be captured?
There was a problem hiding this comment.
Yeah, this note is pretty crappy. I've updated all such instances with
This feature may be blocked by a Permissions Policy set on your server.
Or some slight variation of it.
| To use this sensor, the user must grant permission to the `'accelerometer'`, device sensor through the [Permissions API](/en-US/docs/Web/API/Permissions_API). | ||
|
|
||
| If a feature policy blocks the use of a feature, it is because your code is inconsistent with the policies set on your server. This is not something that would ever be shown to a user. The {{httpheader('Feature-Policy')}} HTTP header article contains implementation instructions. | ||
| If a Permissions Policy blocks the use of a feature, it is because your code is inconsistent with the policies set on your server. This is not something that would ever be shown to a user. Our [Permissions Policy](/en-US/docs/Web/HTTP/Permissions_Policy) article contains implementation instructions. |
There was a problem hiding this comment.
There was a problem hiding this comment.
Updated as per comment above.
|
@chrisdavidmills I have fixed the merge issues, and re-reviewed.
Once you've had a chance to look I'd be happy to merge. It's a mammoth PR so I can imagine I have missed things, but I am also sure it is way better than what preceded it. |
|
This pull request has merge conflicts that must be resolved before it can be merged. |
|
@yin1999 Would you have a chance to look into this error? 🙏 |
I'll have a look on it |
Hi @caugner, I found the problem: When we pass I've created #22898 to fix this. |
…cy-to-permissions-policy
No worries, thanks for the quick fix! 🎉 |
|
Let us all bow before @chrisdavidmills ! |
|
@hamishwillee awesome, just awesome! |
Description
This PR aims to do the work of migrating the existing
Feature-Policydocs over toPermissions-Policy, as described in #22347See my research document at https://docs.google.com/document/d/14xHANU3n43PfJR_dCpEwVCiVYv12BAfGqOICNvd79R4/edit#heading=h.mahbkxhoku5t for a list of the
Permissions-Policydirectives I am intending to implement on MDN as part of this work. This gives us parity with what was previously documented underFeature-Policy, but it adds a few more that are known to be supported, and it removes mention of some that were obviously being worked on at some point, but never seem to have gotten any traction.Also see the equivalent BCD changes at mdn/browser-compat-data#18250
Notes:
Motivation
Additional details
Related issues and pull requests