Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

using region: "US" causes the fetch to fail #815

Closed
scdozer opened this issue Nov 7, 2023 · 1 comment
Closed

using region: "US" causes the fetch to fail #815

scdozer opened this issue Nov 7, 2023 · 1 comment
Labels
triage me I really want to be triaged. type: question Request for information or clarification. Not an issue.

Comments

@scdozer
Copy link

scdozer commented Nov 7, 2023

not sure whats going wrong, but adding region US causes the loader to break. i dont get back any good data, but a "ERR_BLOCKED_BY_CLIENT"

everything seems to work fine without, but hoping to get only USA addresses back

useEffect(() => { const initGoogleServices = async () => { try { const { AutocompleteService, PlacesService } = await new Loader({ apiKey: process.env.NEXT_PUBLIC_GOOGLE_MAPS_API_KEY || "", libraries: ["places"], region: "US", version: "weekly", }).importLibrary("places"); setAutocompleteService(new AutocompleteService()); // Must pass in a HTML div node, so we create a dummy node setPlacesService(new PlacesService(document.createElement("div"))); } catch (error) { console.log("hiiii"); console.error(error); } }; initGoogleServices(); }, []);

@scdozer scdozer added triage me I really want to be triaged. type: question Request for information or clarification. Not an issue. labels Nov 7, 2023
@wangela
Copy link
Member

wangela commented Nov 7, 2023

If you would like to upvote the priority of this issue, please comment below or react on the original post above with 👍 so we can see what is popular when we triage.

@scdozer Thank you for opening this issue. 🙏
Please check out these other resources that might help you get to a resolution in the meantime:

This is an automated message, feel free to ignore.

@scdozer scdozer closed this as completed Nov 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage me I really want to be triaged. type: question Request for information or clarification. Not an issue.
Projects
None yet
Development

No branches or pull requests

2 participants