An Example Blog & Mustache Template System for Perfect
Swift HTML
Latest commit 4a49b81 Oct 19, 2016 @iamjono iamjono committed on GitHub header
Permalink
Failed to load latest commit information.
Sources Initial commit Sep 28, 2016
Tests Initial commit Sep 28, 2016
webroot Initial commit Sep 28, 2016
.gitignore Initial commit Sep 28, 2016
Package.swift Initial commit Sep 28, 2016
README.md header Oct 19, 2016

README.md

Perfect Blog Mustache Example

Get Involed with Perfect!

Star Perfect On Github Stack Overflow Follow Perfect on Twitter Join the Perfect Slack

Swift 3.0 Platforms OS X | Linux License Apache PerfectlySoft Twitter Slack Status

An Example Blog & Mustache Template System for Perfect

This project demonstrates the following:

  • Mustache templating
  • URL routing and handlers
  • URL Variables
  • Static file serving
  • SQLite3 database setup, and search.

This package builds with Swift Package Manager and is part of the Perfect project.

Ensure you have installed Xcode 8.0 or later.

Setup - Xcode 8

  • Check out or download the project;
  • In terminal, navigate to the directory and execute
swift package generate-xcodeproj
  • Open Perfect-Blog-Mustache.xcodeproj

Due to the complexity of running static file serving from Xcode, we suggest running this project from Terminal.

Setup - Terminal

  • Check out or download the project;
  • In terminal, navigate to the directory
  • Execute swift build
  • Once the project has compiled, execute ./.build/debug/Perfect-Blog-Mustache
[INFO] Starting HTTP server on 0.0.0.0:8181 with document root ./webroot

Routes

  • http://localhost:8181 - Generates the list of blog posts
  • http://localhost:8181/story/{storyid} - Linked to from the blog list, this displays the detail of the blog post.

Issues

We are transitioning to using JIRA for all bugs and support related issues, therefore the GitHub issues has been disabled.

If you find a mistake, bug, or any other helpful suggestion you'd like to make on the docs please head over to http://jira.perfect.org:8080/servicedesk/customer/portal/1 and raise it.

A comprehensive list of open issues can be found at http://jira.perfect.org:8080/projects/ISS/issues

Further Information

For more information on the Perfect project, please visit perfect.org.