Asked By: Anonymous
I’m converting a Dart app that uses the GMap lib to Polymer. The map however does not seem to get rendered and nothing else of my app is as well. All I get is a blank screen. I’m not getting a runtime error.
The div where the map is rendered in is in a polymer element. In the Dart file, I’m instantiating the map like this:
final mapOptions = new MapOptions()
..zoom = 15
..center = LAT_LONG_KORTRIJK
..mapTypeId = MapTypeId.ROADMAP;
Element mapView = getShadowRoot("my-element").query("#mapView");
_map = js.retain(new GMap(mapView, mapOptions));
Any ideas on what be going on?
Solution
Answered By: Anonymous
The js package does not support Shadow DOM for now. You are facing to issue-99. Until a native Element support in dart:js
lands I don’t think this issue will be fixed.
Danger Zone : There could perhaps be a dirty way to work around this problem based on this message by manually replacing /packages/js/
with the content of the pointed js branch.