uniapp移动端横竖屏打包后在IOS上无效

hi!今天给各位记录一下在unapp中,当有界面需要横屏显示的时候,在默认开发模式下,是正常的,但打包API后,就不能横屏或者竖屏了。

很简单的两步配置:

一:打开manifest.json~源码视图,在app-plus下进行配置:

bash 复制代码
		"screenOrientation" : [
		   "portrait-primary",
		   "portrait-secondary",
		   "landscape-primary",
		   "landscape-secondary"
		],

附图:

第二步:,配置distribute(应用发布信息),distribute也是在app-plus下:

bash 复制代码
 /* 横竖屏设置 */
				"screenOrientation" : [ "portrait-primary", "landscape-primary" ],
				"distribute" : {
					"screenOrientation" : [ "portrait-primary", "landscape-primary" ]
				},

附图:

好了,再次运行项目,打包个新的API,就可以自动根据屏幕的横竖状态,自动切换了;

相关推荐
茶底世界之下6 小时前
雾中山路的冷光层次:用 Awaking 留住红色背影
ios·app·产品
Digitally8 小时前
iPhone 如何添加日历?
ios·iphone
Gracker1 天前
100 Years Life:把体检、睡眠和运动放进同一份健康档案
ios
秋雨梧桐叶落莳1 天前
【iOS】Block底层详解
macos·ios·cocoa
茶底世界之下1 天前
舞台灯下的萨克斯:用 Awaking 让铜管从蓝幕前亮起来
ios·app·产品
传奇开心果编程1 天前
【Flutter踩坑排雷】第28课:平台目录缺失与修复坑|`flutter create` 的“重建”与“覆盖”边界
android·flutter·ios·移动开发·跨平台·dart·声明式ui
3095566661 天前
股票接口返回 404 与空数组的排查笔记:证书状态与级别参数
java·笔记·python·ios·iphone·股票数据api·股票数据接口
Geek-Chow2 天前
00 Apple Code Signing, In Depth — A Series
ios
传奇开心果编程3 天前
【Flutter踩坑排雷】第25课:ScrollController 误用坑|跳转失效、监听泄漏与“控制器未附加”
android·flutter·ios·移动开发·跨平台·dart·声明式ui
90后的晨仔3 天前
macOS 27 下两个 Xcode 坑:真机 DDI 错配与模拟器 App Translocation
ios