Skip to content

Instantly share code, notes, and snippets.

@davidvanleeuwen
Last active December 15, 2015 01:09
Show Gist options
  • Save davidvanleeuwen/5178354 to your computer and use it in GitHub Desktop.
Save davidvanleeuwen/5178354 to your computer and use it in GitHub Desktop.
Blog container
define ['marionette'], (Marionette) ->
class Blog
constructor: (@options = {}) ->
# Exposed objects under this class.
@Routers = {}
@Views = {}
@Collections = {}
@Models = {}
@Layouts = {}
@App = new Backbone.Marionette.Application()
# To have it globally accessible
window.Blog = new Blog()
window.Blog.App.addRegions
container: 'body'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment