Code Monkey home page Code Monkey logo

iossamplekiturakit's Introduction

Kitura 2 Sample App - ToDo List

Kitura Bird

Travis CI Slack

Kitura is a lightweight and simple web framework that makes it easy to set up complex web routes for web services and applications.

ToDo List demonstrates how Kitura 2s new Codable Routing features can help developers leverage Swift 4's Codable protocol and write code that works on both the front and back end. A new client library is used in the app called KituraKit, which is open source so feel free to contribute!

It is built against a set of ToDoBackend tests to showcase the power of Kitura 2 and its API.

If you would like to import KituraKit into your own iOS project please see KituraKit Usage.

If you would like to view this sample app with an SQL database connected view the persistentiOSKituraKit branch.

Quick Start*

  1. Install Xcode 9 or later.

  2. Clone this repository:

    git clone https://github.com/IBM-Swift/iOSSampleKituraKit.git

  3. Navigate into the ToDoServer folder using:

    cd /iOSSampleKituraKit/ToDoServer/

  4. Run the following commands to compile the code:

    swift build

  5. Start the server with:

    .build/x86_64-apple-macosx10.10/debug/ToDoServer

Note: This command will start the server and it will listen for new connections forever, so the terminal window will be unable to take new commands while the server is running. For more info on the Server component, click here.

  1. Open new Terminal window to continue with the Quick Start.

  2. Navigate into the KituraiOS folder using:

    cd /iOSSampleKituraKit/KituraiOS

  3. Open the iOSKituraKitSample workspace with:

    open iOSKituraKitSample.xcworkspace

A new Xcode window will open. For more info on the iOS app, click here.

  1. Ensure that the Scheme in Xcode is set to the iOS Application. The Scheme selection is located along the top of the Xcode window next to the Run and Stop buttons. If you don't see a Kitura icon (white and blue) in the box next to the Stop button, click the icon that's there and select the App from the drop down menu.

  2. Make sure an iPhone X is selected in the drop down menu next to the Scheme, not "Generic iOS Device". The iPhone Simulators all have blue icons next to their names. iPad is not supported at this time.

  3. Press the Run button or ⌘+R. The project will build and the simulator will launch the application. Navigate your web browser to the address http://localhost:8080 to see an empty array. This is where ToDos made in the app are stored. As you add or delete elements in the app, this array will change.

*The Kitura component can be run on Linux or macOS. Xcode is not required for running the Kitura server component (Xcode is only required for the iOS component).

iossamplekiturakit's People

Contributors

andrew-lees11 avatar kyemaloy97 avatar rolivieri avatar shihabmehboob avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

iossamplekiturakit's Issues

Package cannot find necessary dependencies

The ToDoServer in this package no longer builds, not finding dependencies:
KituraNet and KituraTemplateEngine.

Please see attached end Swift build output.

KituraKit build output.txt

I am dependent on this example in starting a new project and do not know how to resolve this myself.
All help much appreciated.
Kind regards, André Hartman, Belgium

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.