uni-app云打包(正式包和基座)添加VideoPlayer权限后打包报错
uni-app云打包(正式包和基座)添加VideoPlayer权限后打包报错
开发环境 | 版本号 | 项目创建方式 |
---|---|---|
Windows | win10 | HBuilderX |
iOS | iOS 17 | |
苹果 |
操作步骤:
- 打包时勾选VideoPlayer模块儿
预期结果:
- 正常打包
实际结果:
- 报错
bug描述:
当在manifest.json添加视频播放VideoPlayer模块儿后ios不论是打包基座还是打正式包都会报错
报错链接: https://app.liuyingyong.cn/build/errorLog/5a785950-0af2-11f0-b747-01e573d042bc
更多关于uni-app云打包(正式包和基座)添加VideoPlayer权限后打包报错的实战教程也可以访问 https://www.itying.com/category-93-b0.html
3 回复
基座尝试更新到4.57还是打包失败,失败链接https://app.liuyingyong.cn/build/errorLog/f877bf20-0b73-11f0-8b15-bb870a395581
更多关于uni-app云打包(正式包和基座)添加VideoPlayer权限后打包报错的实战教程也可以访问 https://www.itying.com/category-93-b0.html
安卓制作自定义基座成功,但是视频播放模块儿还是黑色的方块,且页面html渲染阻塞,导致页面其他元素渲染异常
这个报错是由于iOS打包时缺少必要的视频播放相关权限配置导致的。需要在manifest.json中正确配置iOS的视频播放权限。
解决方案:
- 在manifest.json的"plus" -> “distribute” -> "ios"节点下添加以下权限配置:
"plistcmds": [
"<key>NSAppTransportSecurity</key>",
"<dict>",
" <key>NSAllowsArbitraryLoads</key>",
" <true/>",
"</dict>",
"<key>NSMicrophoneUsageDescription</key>",
"<string>需要访问麦克风</string>",
"<key>NSPhotoLibraryUsageDescription</key>",
"<string>需要访问相册</string>"
]
- 如果使用到了后台播放功能,还需要添加:
"UIBackgroundModes": ["audio"]