Skip to content

Commit

Permalink
Editorial: consistify the current global object language
Browse files Browse the repository at this point in the history
  • Loading branch information
annevk committed Mar 11, 2022
1 parent f640e53 commit 8470ca2
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions xhr.bs
Original file line number Diff line number Diff line change
Expand Up @@ -406,15 +406,16 @@ the <a>use-CORS-preflight flag</a> to be set.)
case-insensitive match for `<code>CONNECT</code>`, `<code>TRACE</code>`, or `<code>TRACK</code>`.

<p>Throws an "{{InvalidAccessError!!exception}}" {{DOMException}} if <var>async</var> is false,
<a>current global object</a> is a {{Window}} object, and the {{XMLHttpRequest/timeout!!attribute}}
attribute is not zero or the {{XMLHttpRequest/responseType}} attribute is not the empty string.
the <a>current global object</a> is a {{Window}} object, and the
{{XMLHttpRequest/timeout!!attribute}} attribute is not zero or the {{XMLHttpRequest/responseType}}
attribute is not the empty string.
</dl>

<p class=critical id=sync-warning>Synchronous {{XMLHttpRequest}} outside of workers is in the
process of being removed from the web platform as it has detrimental effects to the end user's
experience. (This is a long process that takes many years.) Developers must not pass false for the
<var>async</var> argument when <a>current global object</a> is a {{Window}} object. User agents are
strongly encouraged to warn about such usage in developer tools and may experiment with
<var>async</var> argument when the <a>current global object</a> is a {{Window}} object. User agents
are strongly encouraged to warn about such usage in developer tools and may experiment with
<a lt=throw>throwing</a> an "{{InvalidAccessError!!exception}}" {{DOMException}} when it occurs.

<p>The
Expand Down Expand Up @@ -580,7 +581,7 @@ client.send();
<a><code>send()</code></a> method).

<p>When set: throws an "{{InvalidAccessError!!exception}}" {{DOMException}} if the
<a>synchronous flag</a> is set and <a>current global object</a> is a {{Window}} object.
<a>synchronous flag</a> is set and the <a>current global object</a> is a {{Window}} object.
</dl>

<p>The <dfn attribute for=XMLHttpRequest><code>timeout</code></dfn> getter steps are to return
Expand Down Expand Up @@ -1385,22 +1386,23 @@ steps are:
<dt><code><var>client</var> . <a attribute for=XMLHttpRequest>responseType</a> [ = <var>value</var> ]</code>
<dd>
<p>Returns the response type.

<p>Can be set to change the response type. Values are:
the empty string (default),
"<code>arraybuffer</code>",
"<code>blob</code>",
"<code>document</code>",
"<code>json</code>", and
"<code>text</code>".
<p>When set: setting to "<code>document</code>" is ignored if
<a>current global object</a> is <em>not</em> a
{{Window}} object.

<p>When set: setting to "<code>document</code>" is ignored if the <a>current global object</a> is
not a {{Window}} object.

<p>When set: throws an "{{InvalidStateError!!exception}}" {{DOMException}} if <a>state</a> is
<i>loading</i> or <i>done</i>.

<p>When set: throws an "{{InvalidAccessError!!exception}}" {{DOMException}} if the
<a>synchronous flag</a> is set and <a>current global object</a> is a {{Window}} object.
<a>synchronous flag</a> is set and the <a>current global object</a> is a {{Window}} object.
</dl>

<p>The <dfn attribute for=XMLHttpRequest><code>responseType</code></dfn> getter steps are to return
Expand Down

0 comments on commit 8470ca2

Please sign in to comment.