Skip to content

Instantly share code, notes, and snippets.

@mbleigh
Created August 27, 2011 14:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mbleigh/1175429 to your computer and use it in GitHub Desktop.
Save mbleigh/1175429 to your computer and use it in GitHub Desktop.
GameRouter = new Backbone.Router.extend
routes:
"start": "start"
"draw": "draw"
start: ->
this.navigate('/draw')
draw: ->
$('#sketchpad .front > div').hide()
$('#draw').show()
$('#sketchpad').removeClass("flipped")
window.game = new GameRouter
Backbone.history.start root: "/play"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment