If you compile your gwt app with -generateJsInteropExports any @JsType is accessible in global scope:
Exporting app:
package foo;
@JsType
public Bar {
public Baz baz = new Baz();
}
Consuming JS:
new Bar().baz.baz1();
Consuming gwt app ( No need for -generateJsInteropExports):
@JsType(isNative = true, name = Bar, namespace = "foo")
public class Bar {
Baz baz;
}
On Mon, Apr 10, 2017 at 11:45 AM Kirill Prazdnikov <pkirill@gmail.com> wrote:
You can also use DOM Elememts as an interop types.
--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at https://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at https://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.
No comments:
Post a Comment