Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

有没有设置默认路由,当router里没有路由的时候跳转默认路由 #22

Open
baixiaosh opened this issue Jul 12, 2016 · 3 comments

Comments

@baixiaosh
Copy link

rt

@progrape
Copy link
Owner

@baixiaosh 对于你不想处理的 url,你可以在最后面加一个通用匹配规则。例如

router.push(list)
    .push(article)
    .push({
        url: '*',
        render: function (){
            return `<h1>404</h1>`;
        }
    })

@baixiaosh
Copy link
Author

谢谢

@baixiaosh
Copy link
Author

设置了这个以后 setDefault 就无效了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants