ngmap
Version:
The Simplest AngularJS Google Maps V3 Directive
27 lines (25 loc) • 950 B
HTML
<html ng-app="myApp">
<head>
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<script src="script-tags-for-development.js"></script>
<script src="USGSOverlay.js"></script>
<script>
var app = angular.module('myApp', ['ngMap']);
app.controller('GroundoverlayCustomCtrl', function(NgMap) {
NgMap.getMap().then(function(map) {
var swBound = new google.maps.LatLng(62.281819, -150.287132);
var neBound = new google.maps.LatLng(62.400471, -150.005608);
var bounds = new google.maps.LatLngBounds(swBound, neBound);
var srcImage = 'https://developers.google.com/maps/documentation/javascript/';
srcImage += 'examples/full/images/talkeetna.png';
new USGSOverlay(bounds, srcImage, map);
});
});
</script>
</head>
<body ng-controller="GroundoverlayCustomCtrl as vm">
<ng-map zoom="11" center="62.323907, -150.109291" map-type-id="SATELLITE">
</ng-map>
</body>
</html>