-
-
Notifications
You must be signed in to change notification settings - Fork 5k
fix #1675 #1677
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
base: dev
Are you sure you want to change the base?
Conversation
shuoldUpdateRoute -> shouldUpdateRoute 😀 |
when will you merge this pr? |
@LinusBorg @posva hello, when will this pr be merged? I will use this feature soon. |
I still have to properly test this. It's a bit weird to never use the |
@posva
we know when we are in history mode(src/history/html5.js) and we are in a browser that doesn't support push state, then we know we have set the fallback option to false manully. if not, we will use src/history/hash.js . so we don't need to check the fallback option, just need to check if we are in history mode and we are in a browser that doesn't support push state. the logical is: when we are in history mode, and the browser doesn't support push state, and the router has already initialized. we should just jump(window.location[replace ? 'replace' : 'assign'](url)). thank you. ps: I have tested this on my ie9 and it works well. |
@posva @LinusBorg hello, is this ok? should I do something? /(ㄒoㄒ)/~~ |
fix #1675
I add a shouldUpdateRoute method which is always true except in html5.js when the route isready and the browser don't support history pushstate(such as ie9)
because only history mode have the chance to disable the updateRoute method
which is force ie9 to history mode(fallback: false, for server render)