-
Notifications
You must be signed in to change notification settings - Fork 4
/
demo.html
30 lines (23 loc) · 976 Bytes
/
demo.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<div id="map" style="height: 300px; width: 300px"></div>
<script src="https://cdn.jsdelivr.net/npm/leaflet@1.7.1/dist/leaflet.js"></script>
<script src="./dist/leaflet.icon-material.js"></script>
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<link rel="stylesheet" href="./dist/leaflet.icon-material.css"></link>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/leaflet@1.7.1/dist/leaflet.css"></link>
<script>
var center = [41.7625, -72.674167]
var map = L.map('map', {
center: center,
zoom: 16
})
var CartoDB_DarkMatter = L.tileLayer('https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png', {
attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors © <a href="https://carto.com/attributions">CARTO</a>',
subdomains: 'abcd',
maxZoom: 19
}).addTo(map)
L.marker(center, {
icon: L.IconMaterial.icon({
iconColor: 'black'
})
}).addTo(map)
</script>