I am writing an iOS app in Swift and I would like to prevent the user from using the app in landscape mode. Is there a way to easily block any view to portrait mode only?
yes you can do the following
Click on the icon of your app:
You should get this:
Then you set only portrait mode
Just go to you app setting -> Deployment Info -> Device Orientation, and tick on "Portrait" only
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With