世博会/IOS
我正在尝试将应用程序推送到应用程序商店,但陷入了这个阶段:我无法更改使用相机、照片和位置的默认权限字符串。您可能很清楚,Apple 要求对请求许可的原因做出详细解释。
在
app.json
中,我更改了 ios.infoPlist.NSCameraUsageDescription
以及 plugins.expo-camera.cameraPermission
处的特定插件权限文本字符串。
它们都不起作用。文字是旧的。
如何才能成功更改此设置?
app.json
:
{
"expo": {
"ios": {
"infoPlist": {
"NSCameraUsageDescription": "This app uses the camera to take a photo of users
for their profiles, and optionally to take a photo of a book that users choose to
manually add to their virtual book shelves."
}
},
"plugins": [
[
"expo-camera",
{
"cameraPermission": "This app uses the camera to take a photo of users
for their profiles, and optionally to take a photo of a book that users choose
to manually add to their virtual book shelves."
}
]
]
}
}
注意:我已阅读并尝试通过此修复:https://docs.expo.dev/guides/permissions/
这是一个超级简单的解决方案。在运行构建之前运行带有
clean
标志的预构建命令:
npx expo prebuild --platform ios --clean