leaflet-geosearch
leaflet-geosearch copied to clipboard
"Google Maps JavaScript API has been loaded directly without loading=async"
Hi , Thanks for the lovely plugin !!! I am using GeoSearchControl in my svelte application with google provider
const provider = new GoogleProvider({ apiKey: "" })
const searchControl = new GeoSearchControl({
marker: { icon: icon},
style: "bar",
searchLabel: "search",
resetButton: mdiMagnify,
provider: provider,
resultList: resultList
});
map.addControl(searchControl);
map.on("geosearch/showlocation", (result) => getCoordinates(result));
Started getting warning from google api "Google Maps JavaScript API has been loaded directly without loading=async" and it has impact on the performance takes 10 - 30 secs for the map to load.
Could you suggest any fixes for this ?
Thank you
Please provide some suggestion
I'm going to guess, but I think it originates from the library we use, @googlemaps/js-api-loader.
Issue has been fixed in the latest version v1.16.6 is there any possibility to update ? @smeijer https://github.com/googlemaps/js-api-loader/commit/2d05217cd728175724e1fcf024e33e21cd9cc4b2
Sure. Happy to merge any pull request fixing this. Please tag me in the PR.
:tada: This issue has been resolved in version 3.11.1 :tada:
The release is available on:
Your semantic-release bot :package::rocket: