GWT entry wrap not used in listeners
Closed this issue · 2 comments
There is a problem with JsInterop that it facilitates and do not propose a solution about the gwt $entry function wrapping. This will make the standard scheduler, error handling and maybe something else to produce unexpected behavior.
I have created this issue just to remember and apply the GWT solution when it gets chosen. There are various pull requests to fix the same problem in the GWT SDK itself (https://gwt-review.googlesource.com/#/q/user/src/com/google/gwt/core/client/internal/Entry.java).
I'm going to close it bc in GWT3/J2CL this has been solved using windows.onerror. And schedule final has been deprecated so the $entry is no longer needed. But might be a good idea to add some warning in the doc saying that using schedule finally in GWT2 mixed with JS callbacks might not work as expected.