"> "> ">
<div id="map"></div>
function initMap() {
/*1. Map 위치 표시*/
const myLatLng = {
lat: 위도,
lng: 경도
}
/*2. Map 생성*/
const element = querySelector(".class_name");
const map = new google.maps.Map(element, {
center: myLatLng,
scrollwhell: false,
zoom: 18
});
/*3. Map Marker 생성*/
const marker = new google.maps.Marker({
positon: myLatLng,
map: map,
title: "Marker_Name"
});
}
<script src="<https://maps.googleapis.com/maps/api/js?key=키입력=initMap>" defer></script>