spine / spine

Lightweight MVC library for building JavaScript applications

Home Page:http://spine.github.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

spine.stack default option problem

kkxlkkxllb opened this issue · comments

commented

i found when i refresh the page,if current matched route is equal the @default value then function active will be call twice else function active will always be call once.
So i think the statement @[@default].active() if @default is not the correct way.

I want my app's root url navigate to a default route, I do this

routes:
    "": ->
        @navigate("/dashboard", replace: true)
    "/dashboard": "dashboard"
    "/account": "account"
    "/teach": "teach"

sounds like you are pretty close to having a test case. If you submit a failing unit test as a pull request that would be great!