没有使用gmap jquery插件定义Gmap

时间:2017-04-05 07:14:32

标签: google-maps jquery-gmap3

我正在尝试使用Gmap jquery插件:

<script src="{{asset('public/gmap.js')}}"></script>

 <div id="map"></div>
    <script>

    new GMaps({
      div: '#map',
      lat: -12.043333,
      lng: -77.028333
    });

    map.addMarker({
      lat: -12.043333,
      lng: -77.028333,
      title: 'Lima',
      click: function(e) {
        alert('You clicked in this marker');
      }
    });

    infoWindow: {
      content: '<p>HTML Content</p>'
    }

    </script>

但是,我在控制台中收到错误

  

GMaps未定义

0 个答案:

没有答案
相关问题