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

martinthomson requested changes on this pull request.



> @@ -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]],

The RFC style guide references sections using "Section 3.1.2.2", capital on Section and no trailing period.

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

Hmm, it's called a content coding, but the header is content-encoding.  I think that `supportedContentEncodings` is probably the best choice, because other than us nerds who work on this stuff, the difference is meaningless.

>            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

"... codings that can be used to encrypt the payload of a push message."

>            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>.

I don't think that you want the MUST requirement here.

"A content coding is indicated using the <a>Content-Encoding</a> header field when requesting the sending of a <a>push message</a> from the <a>push service</a>."   ...Maybe.

-- 
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-34191164

Received on Sunday, 23 April 2017 22:41:50 UTC