Skip to content

Instantly share code, notes, and snippets.

@ebryn
Forked from machty/animations-router-stuff.coffee
Last active December 15, 2015 08:19
Show Gist options
  • Save ebryn/5230288 to your computer and use it in GitHub Desktop.
Save ebryn/5230288 to your computer and use it in GitHub Desktop.
App.Router.map ->
@route "a"
@route "b"
@route "ab"
@route "ba"
App.ARoute = Em.Route.extend
events:
animateToB: ->
@transitionTo('ab')
animate =>
@transitionTo('b')
App.BRoute = Em.Route.extend
events:
animateToA: ->
@transitionTo('ba')
animate =>
@transitionTo('a')
App.AbRoute = Em.Route.extend
isInaccessibleByURL: true
App.BaRoute = Em.Route.extend
isInaccessibleByURL: true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment