I'm creating a GWT application and using Xtend. It seems that when Xtend compiles to Java, it removes comments, so when I try to use JSNI, it turns this:
def native void publish() /*-{
// do some javascript stuff through JSNI
}-*/;
into this:
public native void publish();
How can I configure Xtend to preserve comments or otherwise utilize JSNI with Xtend?
With xtend you can't. As workaround move jsni part to java class https://bugs.eclipse.org/bugs/show_bug.cgi?id=430929