All Projects → kiliankoe → Karte

kiliankoe / Karte

Licence: mit
🗺 Conveniently launch directions in other iOS apps

Programming Languages

swift
15916 projects

Projects that are alternatives of or similar to Karte

Jvfloatingdrawer
An easy to use floating drawer view controller.
Stars: ✭ 1,424 (+1615.66%)
Mutual labels:  cocoapod, navigation
Lottiebottomnavbar
A Customisable bottom navbar with Lottie animation
Stars: ✭ 76 (-8.43%)
Mutual labels:  navigation
Animateddropdownmenu
A clean interface dropdown menu, appears underneath navigation bar to display a list of related items when you click on the navigation title.
Stars: ✭ 70 (-15.66%)
Mutual labels:  navigation
React Native Navigation V2
Up and running with React Native Navigation - V2 - by Wix
Stars: ✭ 73 (-12.05%)
Mutual labels:  navigation
Floating Navigation View
A simple Floating Action Button that shows an anchored Navigation View
Stars: ✭ 1,169 (+1308.43%)
Mutual labels:  navigation
Portal
一个优雅的网站导航,可轻松自定义你想要的内容,适合当首页主页使用
Stars: ✭ 75 (-9.64%)
Mutual labels:  navigation
Kotlin Pokedex
🌀 A Pokedex app using ViewModel, LiveData, Room and Navigation
Stars: ✭ 1,156 (+1292.77%)
Mutual labels:  navigation
Rsband local planner
A ROS move_base local planner plugin for Car-Like robots with Ackermann or 4-Wheel-Steering.
Stars: ✭ 78 (-6.02%)
Mutual labels:  navigation
Phfcomposebarview
Compose bar from iOS 7 Messages.app
Stars: ✭ 1,197 (+1342.17%)
Mutual labels:  cocoapod
Markdown Toc
Generate a markdown TOC (table of contents) for a README or any markdown files, using remarkable. Used by assemble, verb, and lots of other projects on GitHub. API and CLI.
Stars: ✭ 1,185 (+1327.71%)
Mutual labels:  navigation
Chromeliketabswitcher
Provides a tab switcher similar to the one, which is used in Google Chrome on Android
Stars: ✭ 1,177 (+1318.07%)
Mutual labels:  navigation
Vbb Cli
A CLI for Berlin & Brandenburg public transport.
Stars: ✭ 70 (-15.66%)
Mutual labels:  transport
Drawer Menu Swift
Drawer menu implementation in Swift 4
Stars: ✭ 74 (-10.84%)
Mutual labels:  navigation
Friendly Public Transport Format
A format for APIs, libraries and datasets containing and working with public transport data.
Stars: ✭ 69 (-16.87%)
Mutual labels:  transport
Hookrouter
The flexible, and fast router for react that is entirely based on hooks
Stars: ✭ 1,200 (+1345.78%)
Mutual labels:  navigation
Corenavigation
📱📲 Navigate between view controllers with ease. 💫 🔜 More stable version (written in Swift 5) coming soon.
Stars: ✭ 69 (-16.87%)
Mutual labels:  navigation
Swifttwitch
👾 The New Twitch API for iOS; wrapped in Swift goodness 👾
Stars: ✭ 72 (-13.25%)
Mutual labels:  cocoapod
Eeh Navigation
An AngularJS menu module.
Stars: ✭ 74 (-10.84%)
Mutual labels:  navigation
Promotion Menu
RubyMotion gem allowing you to easily setup a facebook or Path style hidden slide menu easily with the ProMotion gem.
Stars: ✭ 78 (-6.02%)
Mutual labels:  navigation
Dart
Extras binding and intent builders for Android apps.
Stars: ✭ 1,203 (+1349.4%)
Mutual labels:  navigation

Karte

Travis GitHub tag (latest SemVer)

Small library for opening a location or route in other popular iOS navigation apps.

Currently supported are Apple Maps, Google Maps, Citymapper, Transit, Lyft, Uber, Navigon, Waze, DB Navigator, Yandex.Navi and Moovit.

Know of any other navigation apps that can be opened via URL scheme or universal link? Please open an issue and/or PR 🙃

Quick Start

Check if an app is installed.

if Karte.isInstalled(.citymapper) {
    print("Citymapper is installed 🎉")
}

Launch a specific app with directions.

let coordinate = CLLocationCoordinate2D(latitude: 52.5162746, longitude: 13.3755153)
let berlin = Karte.Location(name: "Brandenburger Tor Berlin", coordinate: coordinate)
Karte.launch(app: .googleMaps, destination: berlin)

Or directly present the user with an action sheet listing all installed navigation apps to pick from.

Karte.presentPicker(destination: location, presentOn: viewController)

If you need more control in how to present the action sheet (e.g. on an iPad), you can get a configured one from Karte without having it presented directly.

let alert = Karte.createPicker(destination: location)

.launch(), .presentPicker() and .createPicker() have a few extra parameters with default values set that you can change to your liking. Most important to note would be an origin location, which can of course also be specified. Leaving it blank defaults to the user's current location in most apps.

A mode of transport can also be specified, which would then filter unsupported apps from the picker. Be aware that trying to launch an app directly with a specific mode of transport will verify if the app supports that mode and throw a Karte.Error.unsupportedMode otherwise.

Caveat

Please be aware that for .isInstalled(), .presentPicker() and .createPicker() to work you will have to have added the necessary URL schemes to your app's Info.plist beforehand. See Apple's Docs for more info on this. The necessary URL schemes can be found here. You're still free to try and launch apps via Karte.launch(app:to:) regardless of registered URL schemes, although that obviously might result in nothing happening if the app isn't there. Don't forget that even Apple Maps can be "uninstalled" now 😉

The section to add to your Info.plist should look like this:

<key>LSApplicationQueriesSchemes</key>
    <array>
        <string>comgooglemaps</string>
        <string>citymapper</string>
        <string>transit</string>
        <string>lyft</string>
        <string>uber</string>
        <string>navigon</string>
        <string>waze</string>
        <string>dbnavigator</string>
        <string>yandexnavi</string>
        <string>moovit</string>
    </array>

Installation

Karte is available through SwiftPM. Just copy https://github.com/kiliankoe/Karte into Xcode ✌️

Credits

This library is based on CMMapLauncher. Unfortunately development on that library seems to have been stopped, so this is a reimplementation in Swift including a few changes and other apps to make usage even more pleasant 😊

Authors

Kilian Koeltzsch, @kiliankoe

"Karte"?

It's German for "Map" and that seemed fitting 🤷‍♀️

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].