You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
...
app = Sammy('#container', function theCharsheetApp() {
var localGameDefs = ['fabled']; // should be stored in db
var currentGame = 'fabled';
var gameinfo = null;
var self = this;
var currentPage = null;
var locale = [];
var templates = {};
this.init = function() {
//this.setLocation('#/');
this.use('Mustache','ms.html');
for (var path in defaultControllers) {
if (!defaultControllers.hasOwnProperty(path)) continue;
(function(p, n) {
self.log('app::bind ' + p + ' to ' + n);
self.get(p, function() {
var etx = this;
self.log('load controller ' + n);
require(['app/controller/' + n], function(page) {
self.log(page);
self.log('app::controller ' + n + ' open');
if (currentPage && currentPage.hide) {
currentPage.hide(etx);
}
return;
page.show.apply(etx);
currentPage = page;
});
})
})(path, defaultControllers[path]);
}
}
...
Log:
app::bind #/ to default
app::bind #/setup to setup
app::bind #/gamelist to gamelist
app::bind #/loadgame to loadgame
app::bind #/cs/:num/:group to charsheet
app::bind #/open/:name to opengame
Start
load controller opengame
app::controller opengame open
The text was updated successfully, but these errors were encountered:
App.run('#/') doesn't actually changes window hash?
Example:
Log:
app::bind #/ to default
app::bind #/setup to setup
app::bind #/gamelist to gamelist
app::bind #/loadgame to loadgame
app::bind #/cs/:num/:group to charsheet
app::bind #/open/:name to opengame
Start
load controller opengame
app::controller opengame open
The text was updated successfully, but these errors were encountered: