You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In this case, the decorator would automatically call create_proxy and addEventListener, but most importantly it could also introspect the function signature and raise an user friendly error in case the actual signature doesn't match the expected one.
The text was updated successfully, but these errors were encountered:
I like this suggestion. The original syntax is very JS-like (as it supposes to be) and for people who are not familiar with JS, this is an easy mistake to make. With the decorator, it can help to make it easier for beginners.
See the Tracking issue #904 for the context.
Original question on discord
The mistake it this:
The error is this:
One related issue/discussion is #835 .
This could be solved by providing, documenting and encouraging the use of a higher level API. For example:
In this case, the decorator would automatically call
create_proxy
andaddEventListener
, but most importantly it could also introspect the function signature and raise an user friendly error in case the actual signature doesn't match the expected one.The text was updated successfully, but these errors were encountered: