I'm building an mobile app with Meteor. Now if the phone changes orientation, the page no longer renders correctly. So I need to refresh the page after orientation change.
Is there a way to detect the orientation change in Meteor cordova app?
Thanks.
A good point to start is this post that actually covers both Android and iOS platforms:
Detect rotation of Android phone in the browser with JavaScript
We currently have two handlers added with
window.addEventListenerinTemplate.template_name.created.resizeevent is used on Android andorientationchangeevent is used on iOS.