This past year, I have spent quite some time experimenting with Kitura, exploring its features and assessing its ease-of-use. As a lecturer, my goal was to evaluate the state of the server-side Swift ecosystem, to add a back-end component to my iOS course and to eventually create a full course around Swift on the server.

I was pleasantly surprised by what Kitura has to offer, how easy it is to use and how helpful the team is in answering questions on Slack and debugging issues. Along the way, my experiments evolved into an application with an ever-growing set of features and several hundred users. While I will open source and document that application in the coming months, I want to start with something smaller and more approachable. To that end, I rewrote my personal website and blog in Swift.

The result is a simple template rendering app. It shows how to:

  • do basic routing
  • serve static files (stylesheets, scripts, images, …)
  • parse JSON using `Decodable` and `JSONDecoder`
  • render templates using Stencil
  • structure pages using template inheritance

Instructions are included to set up the app on your macOS or Linux machine, as well as deploy to IBM Cloud. I’ve even included instructions to configure a custom domain name, should you wish to use this code for your site as well.

For more information, head over to the repository at:


Join The Discussion

Your email address will not be published. Required fields are marked *