-
-
Save jasonmanners/d079ff582df691fb0f06 to your computer and use it in GitHub Desktop.
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 derby = require('derby') | |
, app = derby.createApp(module) | |
, get = app.get | |
, view = app.view | |
, ready = app.ready | |
, start = +new Date() | |
derby.use(require('../../ui')) | |
derby.use(require('derby-auth/components')) | |
// ROUTES // | |
// Derby routes can be rendered on the client and the server | |
get('/', function(page, model, params) { | |
// Looks like the issue might be here | |
// when userPath is set to 'users.12345' there are no issues | |
var userId = model.get('_userId'); | |
var query = model.query('users').withId(userId); | |
query.subscribe(function(err,user){ | |
model.ref('_user', user); | |
page.render(); | |
}) | |
// page.render(); | |
}) | |
// CONTROLLER FUNCTIONS // | |
ready(function(model) { | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment