Created
February 21, 2023 13:16
-
-
Save TravelTime-Frontend/b3747c434a8253ed1ac883612840bc7e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Map set up | |
// The url template for OpenStreetMap tiles. | |
var osmUrl = "http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png"; | |
// Creates the tile layer | |
var osmTileLayer = L.tileLayer(osmUrl, { minZoom: 8, maxZoom: 15 }); | |
// Adds the tile layer to the map. | |
var map = L.map("map").addLayer(osmTileLayer); | |
// Creates a marker for our departure location and adds it to the map. | |
L.marker(markerCoords).addTo(map); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment