如何将 google 个地点限制为仅限一个国家
How to restrict google places to restrict to only one country
我正在制作 google 地图并使用 "Google Places API" 搜索地点...
我需要的是将地点限制在一个国家或一个特定地区。
如何将 google 个地点限制为仅限一个国家?
谢谢...任何答案都将不胜感激!!
使用选项中的 componentRestrictions
设置国家/地区限制。
for example:
{
componentRestrictions: { country: 'IN' }
}
我正在制作 google 地图并使用 "Google Places API" 搜索地点... 我需要的是将地点限制在一个国家或一个特定地区。 如何将 google 个地点限制为仅限一个国家?
谢谢...任何答案都将不胜感激!!
使用选项中的 componentRestrictions
设置国家/地区限制。
for example:
{
componentRestrictions: { country: 'IN' }
}