redirect from hashbang urls
This commit is contained in:
parent
15d7406d71
commit
580d78e947
|
@ -39,6 +39,8 @@ require 'ext/ember/namespace'
|
||||||
callback()
|
callback()
|
||||||
|
|
||||||
run: (attrs) ->
|
run: (attrs) ->
|
||||||
|
@redirectOnHashbang()
|
||||||
|
|
||||||
console.log "Connecting to #{Travis.config.api_endpoint}"
|
console.log "Connecting to #{Travis.config.api_endpoint}"
|
||||||
app = Travis.App.create(attrs || {})
|
app = Travis.App.create(attrs || {})
|
||||||
# TODO: router expects the classes for controllers on main namespace, so
|
# TODO: router expects the classes for controllers on main namespace, so
|
||||||
|
@ -51,3 +53,6 @@ require 'ext/ember/namespace'
|
||||||
@store = app.store
|
@store = app.store
|
||||||
|
|
||||||
app.initialize()
|
app.initialize()
|
||||||
|
|
||||||
|
redirectOnHashbang: ->
|
||||||
|
location.href = location.href.replace('#!/', '') if location.hash.slice(0, 2) == '#!'
|
||||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user