Re: [w3c/push-api] Add PushManager.supportedContentEncodings (#252)

beverloo commented on this pull request.

Thanks!

> @@ -314,6 +314,10 @@
         specification assumes the use of this protocol; alternative protocols are expected to
         provide compatible semantics.
       </p>
+      <p>
+        The <dfn>Content-Encoding</dfn> HTTP header, described in section 3.1.2.2. of [[!RFC7231]],

Done.

> @@ -642,12 +646,25 @@
       </p>
       <pre class="idl">
         interface PushManager {
+          [SameObject] static readonly attribute FrozenArray&lt;DOMString&gt; supportedContentEncodings;

Agreed - the developer is exposed to the Content-Encoding header more than the fact it accepts a (list of) content coding.

>            Promise&lt;PushSubscription&gt; subscribe(optional PushSubscriptionOptionsInit options);
           Promise&lt;PushSubscription?&gt; getSubscription();
           Promise&lt;PushPermissionState&gt; permissionState(optional PushSubscriptionOptionsInit options);
         };
       </pre>
       <p>
+        The <dfn>supportedContentEncodings</dfn> attribute exposes the sequence of supported content
+        codings using which the payload of a <a>push message</a> can be encrypted. When a content

Done.

>            Promise&lt;PushSubscription&gt; subscribe(optional PushSubscriptionOptionsInit options);
           Promise&lt;PushSubscription?&gt; getSubscription();
           Promise&lt;PushPermissionState&gt; permissionState(optional PushSubscriptionOptionsInit options);
         };
       </pre>
       <p>
+        The <dfn>supportedContentEncodings</dfn> attribute exposes the sequence of supported content
+        codings using which the payload of a <a>push message</a> can be encrypted. When a content
+        coding is used, it MUST be set in the <a>Content-Encoding</a> HTTP header when sending a
+        <a>push message</a> to the <a>push service</a>.

Done. I considered changing it around (sending from the AS) but there's other cases too, so I adopted your suggestion.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/push-api/pull/252#pullrequestreview-34610987

Received on Tuesday, 25 April 2017 16:12:18 UTC