rungwiroon/BlazorGoogleMaps

Google Maps is not displayed

HiZackDavid opened this issue · 5 comments

Google map is not being displayed in our pages :

image

To check if we have anything wrong in our implementation, we copied the sample code for mapEvents, and we still run into the same issue.

image

We receive the following errors :

image
image
image
image

The demo seems to be working (at least it shows the map)

image

Other(s)

  • We tried to use the demo Api Key, but we still run into the same issue

What could i say. Wish you luck finding it. I am out of the ideas :).
IMO try using pure js map first. If it fails than it is zero related to blazor.

What could i say. Wish you luck finding it. I am out of the ideas :). IMO try using pure js map first. If it fails than it is zero related to blazor.

You mention being out of ideas, have you ever run into this issue before ?

Surprisingly i dont use blazor maps. I have very small project where i come up once/twice a year. Thats all. So i couldnt comment from practical side. I still do work on this lib when have time or review PR. From that side didnt get such issues.
403/401 looks like some intranet filtering or some missing checkbox in google console. I doubt it will come from library itself.

Maybe this
#44

I managed to fix the issue using a very specific version of the google maps api. This is thanks to the suggestion made for this stackoverflow question :
https://stackoverflow.com/questions/76944666/google-map-api-gray-box-map-not-displaying

In short, instead of :

<script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key={{API_KEY}}&v=3"></script>

I used :

<script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key={{API_KEY}}&v=3.53"></script>

It still has one issue I am trying to figure out but at least it is now showing a map.

For more info on google api versioning : https://developers.google.com/maps/documentation/javascript/versions#documentation-for-the-api-versions

So happy that you solved and even more that you shared knowledge.
Sharing is caring :)