CHAPTER 7Swift and Kitura for Web Applications

Modern user-facing applications are typically built as two separate parts, a front end and a back end. This is especially true in the enterprise application space. This separation of the front end and back end enables user-facing applications to offer great user experiences and user interfaces, while enforcing enterprise and legal requirements in the server. This also enables multiple front ends, such as mobile apps and web applications with the same back end.

Enterprise applications are typically built with a large set of technologies, often using very different technologies on both the front end and the back end. In larger projects this may not be a problem, as different teams may be writing different parts of the application. In smaller projects where the same people are writing both the client side and the server code, this use of different technologies causes loss of productivity due to mental model switches when people switch “sides” of the application.

Web applications are sometimes written using JavaScript on the client, in the browser, and on the server, using Node.js.

Mobile applications, especially those that use iOS-based clients, have until now also suffered from this problem, with the client side more recently being written in Swift, and the server side being written in Java or JavaScript.

With the open sourcing and porting to Linux of the Swift language, its compiler, debugger, standard library, and the Foundation ...

Get Swift in the Cloud now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.