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

unhandled hash routes -> sets window.location.href #61

Open
thomashandorf opened this issue Jun 12, 2017 · 0 comments
Open

unhandled hash routes -> sets window.location.href #61

thomashandorf opened this issue Jun 12, 2017 · 0 comments
Labels

Comments

@thomashandorf
Copy link
Member

when linking to a hash that is not handled by the hash router (e.g. not a frame, not an anchor or anchor is display:none) this will lead to the router setting window.location.href. This is not necessary when the actual didn’T change. The actual effect is that the onpopstate handling is invoked which trigger the router again.

this can be seen on current landing page with the bootstrap collapsibles. in this case it works as bootstrap sets display:block and thus the router will handle the scroll to on the second run. In other cases that might lead to infinite window.location.href cycling.

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

No branches or pull requests

1 participant