Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CEReactions] and IDL attribute #10023

Open
dSalieri opened this issue Dec 27, 2023 · 0 comments
Open

[CEReactions] and IDL attribute #10023

dSalieri opened this issue Dec 27, 2023 · 0 comments

Comments

@dSalieri
Copy link

dSalieri commented Dec 27, 2023

In the spec we have the following:

The [CEReactions] extended attribute must take no arguments, and must not appear on anything other than an operation, attribute, setter, or deleter. Additionally, it must not appear on readonly attributes.

When attribute applies in IDL it often means the both get and set functions for potential property. But get can't affect to DOM (for the same reason why attribute getter is never used with [CEReactions])

First question: When [CEReactions] is applied to attribute, does it mean that get function will be decorated with [CEReactions] decorator? Sure I don't speak when attribute has readonly, it's obvious.


The second one:

To ensure custom element reactions are triggered appropriately, we introduce the [CEReactions] IDL extended attribute. It indicates that the relevant algorithm is to be supplemented with additional steps in order to appropriately track and invoke custom element reactions.

So [CEReactions] need for correct tracking mutation of custom elements.

Well let's take data element and its value attribute. This attribute decorated with [CEReactions].

Second question: How does value attribute affect on our custom element, if we just change value via js?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant