Created
August 1, 2014 13:28
-
-
Save pauginer/327a7b3ca97d35da5df2 to your computer and use it in GitHub Desktop.
This file contains 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
//To be included on a header script for Hype | |
//Updates the scene when the hash changes (Does not update on initial hash value) | |
$(window).bind( 'hashchange', function(e) { | |
var hash = window.location.hash; | |
var sceneName=hash.replace('#',''); | |
var hypeDocument = HYPE.documents['index'] | |
hypeDocument.showSceneNamed(sceneName, hypeDocument.kSceneTransitionInstant); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment