1

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.

Fei
  • 769
  • 2
  • 7
  • 13

1 Answers1

0

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.addEventListener in Template.template_name.created. resize event is used on Android and orientationchange event is used on iOS.

Community
  • 1
  • 1
romaroma
  • 658
  • 8
  • 13