Getting Started
Copiez un prompt de configuration avec les étapes d'installation et la guide markdown complète pour ce plugin.
Set up this Capacitor plugin in the project.
Use the package manager already used by the project.
Install these package(s): `@capgo/capacitor-launch-navigator`
Run the required Capacitor sync/update step after installation.
Read this markdown guide for the full setup steps: https://raw.githubusercontent.com/Cap-go/website/refs/heads/main/apps/docs/src/content/docs/docs/plugins/launch-navigator/getting-started.mdx
Use that guide for platform-specific steps, native file edits, permissions, config changes, imports, and usage setup.
If that guide references other docs pages, read them too.
Installer
Section intitulée « Installer »bun add @capgo/capacitor-launch-navigatorbunx cap syncImporter
Section intitulée « Importer »import { LaunchNavigator } from '@capgo/capacitor-launch-navigator';API Aperçu
Section intitulée « API Aperçu »navigate
Section intitulée « Naviguer »Naviguer à une emplacement en utilisant la latitude et la longitude
import { LaunchNavigator } from '@capgo/capacitor-launch-navigator';
await LaunchNavigator.navigate({} as { /** * Destination coordinates [latitude, longitude] */ destination: [number, number];
/** * Optional navigation options */ options?: NavigateOptions; });isAppAvailable
Section intitulée « estDisponible »Vérifiez si une application de navigation spécifique est disponible
import { LaunchNavigator } from '@capgo/capacitor-launch-navigator';
await LaunchNavigator.isAppAvailable({} as { /** * App identifier to check */ app: IOSNavigationApp | AndroidNavigationApp | string; });getAvailableApps
Section intitulée “getAvailableApps”Obtenez la liste des applications de navigation disponibles sur le dispositif
import { LaunchNavigator } from '@capgo/capacitor-launch-navigator';
await LaunchNavigator.getAvailableApps();getSupportedApps
Section intitulée “getSupportedApps”Obtenez la liste des applications prises en charge pour la plateforme actuelle
import { LaunchNavigator } from '@capgo/capacitor-launch-navigator';
await LaunchNavigator.getSupportedApps();getDefaultApp
Section intitulée “getDefaultApp”Obtenez le nom de l'application par défaut pour la navigation
import { LaunchNavigator } from '@capgo/capacitor-launch-navigator';
await LaunchNavigator.getDefaultApp();Référence de type
Section intitulée « Type Reference »NavigateOptions
Section intitulée « NavigateOptions »Options de navigation.
export interface NavigateOptions { /** * Starting location coordinates [latitude, longitude] */ start?: [number, number];
/** * Starting location name */ startName?: string;
/** * Destination name (will be ignored since we only support coordinates) */ destinationName?: string;
/** * Transport mode */ transportMode?: TransportMode;
/** * Specific app to launch (if not specified, will use default or prompt) */ app?: IOSNavigationApp | AndroidNavigationApp | string;
/** * Launch mode */ launchMode?: LaunchMode;
/** * Additional parameters specific to certain apps */ extras?: Record<string, any>;
/** * Enable debug logging */ enableDebug?: boolean;}IOSNavigationApp
Section intitulée « IOSNavigationApp »Applications de navigation disponibles pour iOS.
export enum IOSNavigationApp { APPLE_MAPS = 'apple_maps', GOOGLE_MAPS = 'google_maps', WAZE = 'waze', CITYMAPPER = 'citymapper', GARMIN_NAVIGON = 'garmin_navigon', TRANSIT_APP = 'transit_app', YANDEX_NAVIGATOR = 'yandex', UBER = 'uber', TOMTOM = 'tomtom', SYGIC = 'sygic', HERE_MAPS = 'here', MOOVIT = 'moovit', LYFT = 'lyft', MAPS_ME = 'mapsme', CABIFY = 'cabify', BAIDU = 'baidu', GAODE = 'gaode', TAXI_99 = '99taxi',}AndroidNavigationApp
Section intitulée « AndroidNavigationApp »Applications de navigation disponibles pour Android.
export enum AndroidNavigationApp { GOOGLE_MAPS = 'google_maps', WAZE = 'waze', CITYMAPPER = 'citymapper', UBER = 'uber', YANDEX = 'yandex', SYGIC = 'sygic', HERE_MAPS = 'here', MOOVIT = 'moovit', LYFT = 'lyft', MAPS_ME = 'mapsme', CABIFY = 'cabify', BAIDU = 'baidu', GAODE = 'gaode',}AvailableApp
Section intitulée « AvailableApp »Résultat de la vérification de la disponibilité de l'application.
export interface AvailableApp { /** * App identifier */ app: string;
/** * Display name of the app */ name: string;
/** * Whether the app is available on the device */ available: boolean;}TransportMode
Section intitulée “Mode de transport”Modes de transport.
export enum TransportMode { DRIVING = 'driving', WALKING = 'walking', BICYCLING = 'bicycling', TRANSIT = 'transit',}LaunchMode
Section intitulée “Mode de lancement”Modes de lancement.
export enum LaunchMode { MAPS = 'maps', TURN_BY_TURN = 'turn_by_turn', GEO = 'geo',}Source de Vérité
Section intitulée “Source de Vérité”Cette page est générée à partir du plugin’s src/definitions.ts. Re-run the sync when the public API changes upstream.
Continuez de Getting Started
Section intitulée « Continuez depuis Getting Started »Si vous utilisez Getting Started pour planifier le tableau de bord et les opérations API, connectez-le à Utilisez @capgo/capacitor-launch-navigator pour la capacité native dans Utilisez @capgo/capacitor-launch-navigator, Vue d'ensemble de API pour les détails d'implémentation dans Vue d'ensemble de API, Introduction pour les détails d'implémentation dans Introduction, Clés de API pour les détails d'implémentation dans Clés de API, et Appareils pour le détail d'implémentation dans Appareils.