Skip to content

Commit

Permalink
Put trusted type first when declaring union in IDL files (#564)
Browse files Browse the repository at this point in the history
This is for consistency with how it is done in the HTML specification
and in the PR to DOM (whatwg/dom#1268). This
is not web-exposed but may matter for implementations. For example,
they may generate different C++ structure to represent
`(TrustedHTML or DOMString)` and `(DOMString or TrustedHTML)`.
  • Loading branch information
fred-wang authored Nov 18, 2024
1 parent 4317ed0 commit f97dbe9
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions spec/index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1146,10 +1146,10 @@ Note: Using these IDL attributes is the recommended way of dynamically setting t

<pre class="idl exclude">
partial interface HTMLScriptElement {
[CEReactions] attribute ([LegacyNullToEmptyString] DOMString or TrustedScript) innerText;
[CEReactions] attribute (DOMString or TrustedScript)? textContent;
[CEReactions] attribute (USVString or TrustedScriptURL) src;
[CEReactions] attribute (DOMString or TrustedScript) text;
[CEReactions] attribute (TrustedScript or [LegacyNullToEmptyString] DOMString) innerText;
[CEReactions] attribute (TrustedScript or DOMString)? textContent;
[CEReactions] attribute (TrustedScriptURL or USVString) src;
[CEReactions] attribute (TrustedScript or DOMString) text;
};
</pre>

Expand Down

0 comments on commit f97dbe9

Please sign in to comment.