/hotel-lister-cordova

Learn how to build a Cordova Plugin to use Couchbase Lite in your iOS and Android apps

Primary LanguageJava

Installation

  1. Clone the repo

    git clone https://github.com/couchbaselabs/hotel-lister-cordova
  2. Run the following commands in your Terminal.

    cd modules/hotel-lister/examples/HotelLister
    npm install -g ionic cordova
    npm install
  3. Run the application on the iOS or Android simulator. First, you can list available simulators with the following command.

    ionic cordova emulate --list

    Then, use the --target option to specify the simulator to deploy the app to.

    ionic cordova emulate ios --target "iPhone-XR, 12.0" -- --buildFlag="-UseModernBuildSystem=0"
    # or
    ionic cordova emulate android
  4. You should see the following appear on the simulator.

    ionic listing hotels
    Note
    On iOS, you will need to download Couchbase Lite from couchbase.com/downloads and drag CouchbaseLiteSwift.framework to the Xcode project under platforms/ios/Frameworks.