Created
March 29, 2013 03:23
-
-
Save joeldbirch/5268562 to your computer and use it in GitHub Desktop.
Seems to be the only way to reset Apple's hacky iOS "hover" state after back button click. Uses jQuery event attachment, but can be easily swapped for addEventListener.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (/iPhone|iPad|iPod/i.test(navigator.userAgent)) { | |
$(window).on('pageshow', function(e) { | |
if (e.originalEvent.persisted) { | |
window.location.reload(); | |
} | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment