react-native-orientation
react-native-orientation copied to clipboard
Orientation is not working in real device which ios 14+
Hello,
Recently i have start facing this issue in ios 14+ that device orientation is not working in ios but working fine in android i don't received any error for this
already imported orientation.h file in appdelegate and method
- (UIInterfaceOrientationMask)application:(UIApplication *)application supportedInterfaceOrientationsForWindow:(UIWindow *)window { return [Orientation getOrientation]; }
still not able to know why its stopped working
"react-native-orientation": "^3.1.3", "react": "17.0.1", "react-native": "0.64.1",
these are the specs please provide some suggestions
also received this error for ios 16
None of the requested orientations are supported by the view controller. Requested: landscapeLeft; Supported: portrait
yes I too facing the same issue, on ios 16, the orientation is not working, Can someone please help?
https://github.com/yamill/react-native-orientation/issues/411 we are still waiting for fixes.
hii @pawansharmaAccolite did you fix the issue i am also facing same problem please need urgenthelpp
@swaroopaillinda You can use patch-package to this patch react-native-orientation+3.1.3.patch for hot fix https://gist.github.com/catmans1/1c980c27e6ac28439a7ec5e1063fd8ef
Store it in the folder patches
in package.json
{
...
"scripts": {
...
"postinstall": "npx patch-package"
},
...
}
@swaroopaillinda You can use patch-package to this patch react-native-orientation+3.1.3.patch for hot fix https://gist.github.com/catmans1/1c980c27e6ac28439a7ec5e1063fd8ef
Store it in the folder
patches
in package.json
{ ... "scripts": { ... "postinstall": "npx patch-package" }, ... }
This patch seems to work for me