Created
April 18, 2012 17:01
-
-
Save artjumble/2415038 to your computer and use it in GitHub Desktop.
Simplistic derby
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var app = require('derby').createApp(module) | |
, get = app.get | |
, view = app.view | |
, ready = app.ready | |
// ROUTES // | |
// Derby routes can be rendered on the client and the server | |
get('/', function(page, model, params) { | |
page.render() | |
}) | |
// CONTROLLER FUNCTIONS // | |
ready(function(model) { | |
exports.reload = function() { | |
window.location.reload() | |
} | |
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Title:> | |
visits | |
<Body:> | |
<h1>sdf</h1> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This it might be like this