Polymer core-drawer-panel throws exception at loading

163 views Asked by At

I'm in dead end doing my own version of this GWT-Polymer project hosted at GitHub. Its fully working in the IDE, but at devsever it throws following error.

Error image pasted inline

if (src != null && !canCast(src, dstId)) {
  throw new ClassCastException();
}

canCast() returns false, because core-drawer-panel is not a JavaString (look debug image), its HTML. Core-draw-panel can be found in Polymer GitHub.

So what i should do? Version info:

  • Polymer 0.5
  • GWT 2.7
  • JAVA 7
1

There are 1 answers

2
Manolo Carrasco Moñino On BEST ANSWER

GWT-Polymer uses a new feature in GWT called JsInterop, so I think the error you are getting is because you are not using the compiler flag to enable it.

Try to add to your compiler the option:

-XjsInteropMode JS

BTW, gwt-polymer is using gwt-2.8.0-SNAPSHOT which have last features, so probably you have to depend in your project on the snapshot.