Commit dfb4fda3 authored by Luna Lu's avatar Luna Lu Committed by Commit Bot

Update feature policy syntax in README

Bug: 761003
Change-Id: If6404fb5ee6866777ccd2bfacce1f7d235fdd17b
Reviewed-on: https://chromium-review.googlesource.com/794047
Commit-Queue: Luna Lu <loonybear@chromium.org>
Reviewed-by: default avatarIan Clelland <iclelland@chromium.org>
Cr-Commit-Position: refs/heads/master@{#521797}
parent e7a0f1c8
......@@ -28,7 +28,7 @@ HTTP tests are used to test features with header policy.
* Define the header policy in `<feature-name>-<enabled | disabled | enabled-on-self-origin>-by-feature-policy.https.sub.html.headers`. Example:
Feature-Policy: {"feature-name": ["*"]}
Feature-Policy: feature-name *
* In `<feature-name>-<enabled | disabled | enabled-on-self-origin>-by-feature-policy.https.sub.html`:
......
......@@ -11,14 +11,7 @@ via a HTTP header and/or an iframe "allow" attribute.
Below is an example of a header policy (note that the header should be kept in
one line, split into multiple for clarity reasons):
Feature-Policy: {"vibrate": [],
"geolocation": ["self", "https://example.com"],
"camera": ["*"]}
Soon the syntax will be updated
([crbug.com/750259](https://bugs.chromium.org/p/chromium/issues/detail?id=750259)):
Feature-Policy: vibrate "none"; geolocation "self" https://example.com; camera "*"
Feature-Policy: vibrate 'none'; geolocation 'self' https://example.com; camera *
- `vibrate` is disabled for all browsing contexts;
......@@ -28,16 +21,11 @@ Soon the syntax will be updated
Below is an example of a container policy:
<iframe allowpaymentrequest allow=’vibrate fullscreen’></iframe>
Soon the syntax will be updated
([crbug.com/726739](https://bugs.chromium.org/p/chromium/issues/detail?id=726739)):
<iframe allowpaymentrequest allow='vibrate; fullscreen;'></iframe>
<iframe allowpaymentrequest allow='vibrate; fullscreen'></iframe>
OR
<iframe allowpaymentrequest allow='vibrate "src"; fullscreen "src"'></iframe>
<iframe allowpaymentrequest allow="vibrate 'src'; fullscreen 'src'"></iframe>
- `payment` is enabled (via `allowpaymentrequest`) on all browsing contexts
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment