Skip to content

Commit 34918d9

Browse files
committed
PROCESS: API key should not be required to setup a development server.
1 parent 831ec76 commit 34918d9

3 files changed

Lines changed: 20 additions & 21 deletions

File tree

public/index.html

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@
2222
padding: 0;
2323
}
2424
</style>
25-
<script src="settings.js?key=AIzaSyAtl1YBvhlhE_jJp-Bl1kVYigPaJfiti10"></script>
2625
<script src="maps.js"></script>
2726
</head>
2827
<body>

public/maps.js

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,22 @@
1+
const settings = {
2+
coverage: {
3+
draggableCursor: 'pointer',
4+
center: {lat: 37.977950, lng: 23.718200},
5+
zoom: 18,
6+
mapTypeId: 'satellite'
7+
},
8+
overlays: [
9+
[
10+
'https://steatite.utt.fr/picture/405e66c63060b595c02e6590a8f6abbda104cb03',
11+
{south: 37.977910, west: 23.718200, north: 37.978780, east: 23.719010}
12+
],
13+
[
14+
'https://steatite.utt.fr/picture/78e81db6ee77decd3e40cf3124c04a6aaaaa2fc4',
15+
{south: 37.97862453543905, west: 23.716649743986387, north: 37.978755, east: 23.716789}
16+
]
17+
]
18+
};
19+
120
let createMap = (id) => new google.maps.Map(document.getElementById(id), settings.coverage);
221

322
let fillForm = (latitude, longitude, title = '') => {
@@ -16,7 +35,7 @@ let putOverlaysOnMap = (map) => settings.overlays.map(x => new google.maps.Groun
1635
x.addListener('click', showLocation);
1736
});
1837

19-
let getLocation = (address) => fetch(`/json?address=${address}&key=${settings.key}`)
38+
let getLocation = (address) => fetch(`/json?address=${address}`)
2039
.then(x => x.json())
2140
.then(x => ({
2241
title: address,

public/settings.js

Lines changed: 0 additions & 19 deletions
This file was deleted.

0 commit comments

Comments
 (0)