Hey there,
I've got my document set up to display a certain scene based on the browser size, it's working well:
if (window.innerWidth <= 899) {
hypeDocument.showSceneNamed('m');
}
else {
hypeDocument.showSceneNamed('d');
}
However, I'd like to also detect if the window has been resized to also change to the proper scene layout based on the browser size. How can I detect if the window size has been changed?
Thanks
Thanks for the quick reply. I put this in the same javascript that the scene runs on load. Doesn't seem to be detecting resize. Should put this javascript somewhere else (in the head)