allenhwkim / angularjs-google-maps

The Simplest AngularJS Google Maps V3 Directive
http://ngmap.github.io
MIT License
1.52k stars 517 forks source link

Info window is not show when first sub element is a comment #841

Open taitruong opened 7 years ago

taitruong commented 7 years ago

You can reproduce the bug with this snippet (taken from issue 648):

    <marker id="event-location"
            position="1163 pandora, victoria, bc, canada">
    </marker>

    <info-window id="event-location-info"
                 visible-on-marker="event-location">
      <!-- BUG here: comment causing info-window-error, remove this line and it work's like a charm -->
      <div ng-non-bindable>
        Test
      </div>
    </info-window>

In this case you get an 'info-window working as a template must have a container'-error. By removing the comment it works fine. It took me a while figuring that out.

HTH, Tai