gusto
v0.0.4b
Published
Unfancy MVC
Downloads
8
Readme
Gusto
...is an MVC framework written in Coco for Node. It's geared towards flexibility without sacrificing simplicity, and at a mere ~500loc it's lightweight too. It's released under the MIT Licence, so hack away. ##Sample ###controllers/site.co
{Controller,action} = require \gusto/lib/mvc/controller
{get} = require \gusto/lib/server/router
exports.site = Controller {
index: get "home", action (self)->
self.render greet:"world!"
}
###views/site/index.eco
Hello #{greet}
###run.co
Gusto = require \gusto
app = Gusto.defaults!
app.listen 8001
$ coco run.co &
LOG 5174 Listening on *:8001
$ curl http://localhost/home
Hello world!