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

BUG: href.js doesn't trigger callback in IE #82

Open
oderby opened this issue Feb 25, 2017 · 2 comments
Open

BUG: href.js doesn't trigger callback in IE #82

oderby opened this issue Feb 25, 2017 · 2 comments

Comments

@oderby
Copy link

oderby commented Feb 25, 2017

Clicking on an anchor element in IE doesn't trigger the callback passed to href to be called. I believe this is because the logic for finding the anchor node containing the href doesn't work properly in IE, specifically line 24, which checks if the found anchor points to the same host as the current window, because the host property of anchor elements is not available on IE (nor Safari, for that matter).

@yoshuawuyts
Copy link
Owner

yoshuawuyts commented Feb 26, 2017 via email

@oderby
Copy link
Author

oderby commented Feb 26, 2017

I'd be surprised if someone hasn't already written the logic to simulate/polyfill the host property - afterall, it should be deterministic given the href, right? I'm sure there are some corner cases, but you should be able to just pull in the bits you need, if you don't want the bloat of adding a whole library to do it.

jhnns added a commit to jhnns/sheet-router that referenced this issue Jun 26, 2017
jhnns added a commit to jhnns/sheet-router that referenced this issue Jun 26, 2017
jhnns added a commit to jhnns/sheet-router that referenced this issue Jun 26, 2017
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