- From: Tab Atkins Jr. <notifications@github.com>
- Date: Sun, 26 Jan 2020 20:42:04 -0800
- To: heycam/webidl <webidl@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <heycam/webidl/pull/836/review/348438176@github.com>
tabatkins commented on this pull request.
> +Mutations to this list (e.g. by [=list/appending=] to it) will be visible to authors, and any
+mutations by authors to the observable array's contents (e.g. by using
+<code>obj.observableArrayAttr.push(value)</code>) will be observable as changes to the list, after
+running through the above hooks.
+
+Every attribute whose type is an observable array type has a
+<dfn>backing <code>ObservableArray</code></dfn>, which is an instance of the {{ObservableArray}}
+interface, whose [=ObservableArray/type=] is |T|, [=ObservableArray/before hook=] is the
+[=observable array attribute/before hook=] defined for the attribute, if any, and
+[=ObservableArray/after hook=] is the [=observable array attribute/after hook=] defined for the
+attribute, if any. Specification authors do not need to interface with this directly; instead they
+can use the above mechanisms.
+
+There is no way to represent a constant observable array value in IDL.
+
+The [=type name=] of a frozen array type is the concatenation of the type name for |T| and the
```suggestion
The [=type name=] of an observable array type is the concatenation of the type name for |T| and the
```
> @@ -8819,6 +8957,15 @@ value is the Object value that represents a reference
to the same object that the IDL <a interface lt="FrozenArray">FrozenArray<|T|></a> represents.
+<h4 id="es-observable-array">Observable arrays — ObservableArray<|T|></h4>
+
+Values of observable array types are represented by ECMAScript objects representing
+{{ObservableArray}} interface instances, with their [=ObservableArray/type=] set to |T|.
+
+Instead of the usual conversion algorithms, observable array types have special handling as part of
+the [=attribute getter=] and [=attribute setter=] algorithms.
+
+
<h5 id="create-frozen-array-from-iterable" dfn>Creating a frozen array from an iterable</h5>
Several instances of "frozen" still present in this section. Also this ends up removing the actual "create a frozen array from an iterable" section, which I suspect wasn't intended.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/heycam/webidl/pull/836#pullrequestreview-348438176
Received on Monday, 27 January 2020 04:42:06 UTC