Integrating Google Maps in Angular

preview_player
Показать описание
Install Google Maps types for typescript support.
Run command
npm install --save @types/googlemaps

NOTE: Make sure you put your Google Map API Key here.

Next, let’s add a placeholder div for Google Map -- #map

div #map

//-- code --
ngAfterViewInit() {
}

loadMap() {
51.4088381,-104.5368283
);
let mapOptions = {
center: latLng,
zoom: 15,
};

}
Рекомендации по теме