指南
Native Geocoder 的教程
使用 @capgo/capacitor-nativegeocoder
Capacitor native地理编码插件
Install
npm install @capgo/capacitor-nativegeocoder
npx cap sync
What This Plugin Exposes
reverseGeocode- 将经纬度转换为地址forwardGeocode- 将地址转换为经纬度
Example Usage
reverseGeocode
将经纬度转换为地址
import { NativeGeocoder } from '@capgo/capacitor-nativegeocoder';
await NativeGeocoder.reverseGeocode({} as ReverseOptions);
forwardGeocode
将地址转换为经纬度
import { NativeGeocoder } from '@capgo/capacitor-nativegeocoder';
await NativeGeocoder.forwardGeocode({} as ForwardOptions);
Full Reference
- GitHub native地理编码插件 https://github.com/Cap-go/capacitor-nativegeocoder/
- Docs: /docs/plugins/nativegeocoder/
继续使用 @capgo/capacitor-nativegeocoder
如果您正在使用 使用 @capgo/capacitor-nativegeocoder 来规划原生插件工作,连接它与 @capgo/capacitor-nativegeocoder 了解 @capgo/capacitor-nativegeocoder 中的实现细节 Getting Started 了解 Getting Started 中的实现细节 Capgo 插件目录 了解 Capgo 插件目录 中的产品工作流程 Capacitor 由 Capgo 提供的插件 了解 Capacitor 由 Capgo 提供的插件 中的实现细节 添加或更新插件 为添加或更新插件提供实现细节。