Last active
August 29, 2015 14:02
-
-
Save enricostano/e04c907d9ff0931a0572 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
'use strict'; | |
require("../../lib/bootstrap-3.1.1-dist/css/bootstrap.css"); | |
require("../styles/main.css"); | |
require("imports?jQuery=jquery!../../lib/bootstrap-3.1.1-dist/js/bootstrap.js"); | |
var Backbone = require("backbone") | |
, Marionette = require("backbone.marionette") | |
, headerLayoutTemplate = require("../templates/header.handlebars") | |
, Katuma = new Marionette.Application({}); | |
Katuma.rootRoute = "/"; | |
Katuma.addRegions({ | |
navRegion: "#js-nav-region" | |
, contentRegion: "#js-content-region" | |
}); | |
Katuma.headerLayout = Backbone.Marionette.Layout.extend({ | |
template: headerLayoutTemplate() | |
, regions: { | |
login: "#js-nav-login" | |
} | |
}); | |
Katuma.addInitializer(function(options) { | |
var headerLayout = new Katuma.headerLayout(); | |
Katuma.navRegion.show(headerLayout); | |
}); | |
Katuma.on("initialize:after", function(){ | |
Backbone.history.start(); | |
}); | |
Katuma.start(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment