GithubHelp home page GithubHelp logo

cartona / capacitor-start-navigation Goto Github PK

View Code? Open in Web Editor NEW

This project forked from proteansoftware/capacitor-start-navigation

0.0 0.0 0.0 95 KB

License: MIT License

JavaScript 3.47% Ruby 12.70% Objective-C 9.12% Java 27.46% TypeScript 17.81% Swift 29.44%

capacitor-start-navigation's Introduction

capacitor-start-navigation npm version

Capacitor plugin that allows your app to start native navigation

API

method info platform
launchMapsApp Launches native maps with navigation started. ios/android

Usage

import { StartNavigation } from "@proteansoftware/capacitor-start-navigation";

//
// launches native maps with directions to Warwick, UK
StartNavigation.launchMapsApp({
  latitude: 52.28333,
  longitude: -1.58333,
  name: "Example location"
});

iOS setup

  • sudo gem install cocoapods (once a time)
  • ionic start my-cap-app --capacitor
  • cd my-cap-app
  • mkdir www && touch www/index.html
  • npx cap add ios
  • npm install --save @proteansoftware/capacitor-start-navigation
  • npx cap sync ios (always do sync after a plugin install)
  • npx cap open ios

Android setup

  • ionic start my-cap-app --capacitor
  • cd my-cap-app
  • mkdir www && touch www/index.html
  • npx cap add android
  • npm install --save @proteansoftware/capacitor-start-navigation
  • npx cap sync android (always do sync after a plugin install)
  • npx cap open android
  • [extra step] in android case we need to tell Capacitor to initialise the plugin:

on your MainActivity.java file add import com.servicesight.capacitor.startnavigation.StartNavigationPlugin; and then inside the init callback add(StartNavigationPlugin.class);

Now you should be set to go. Try to run your client using ionic cap run android --livereload.

License

MIT

capacitor-start-navigation's People

Contributors

dependabot[bot] avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.