Map is not working in Server-Client UI
Closed this issue · 1 comments
Update: I just realized adding <script> tag with API_KEY makes the map work only in Chrome incognito mode.
Since now it requires to use API_KEY , I tried to add key in app.js file however the map does not load and displays the MissingKeyMap Error.
I am running the server on localhost:3000. I even tried replacing my own api key but no luck.
Can you please help how can I fix this.
app.js
.config(['uiGmapGoogleMapApiProvider', function(uiGmapGoogleMapApiProvider) {
var config = {
key: 'AIzaSyCU86vupyU0nMI7QvDnfJXteNxLyfrMSDg',
v: '3.3', //defaults to latest 3.X anyhow
libraries: 'weather,geometry,visualization'
}
if ((/herokuapp/).test(window.location.host))
config.key = 'AIzaSyCU86vupyU0nMI7QvDnfJXteNxLyfrMSDg'
uiGmapGoogleMapApiProvider.configure(config);
}])
.config(['cfpLoadingBarProvider', function(cfpLoadingBarProvider) {
cfpLoadingBarProvider.includeSpinner = false;
}])
Am I missing anything ?
Resolved, using new API key and appending & . API_KEY + &