在 Info.plist 中,<string></string>

问题描述 投票:0回答:1

我将以下文本添加到 Info.plist 中,以尝试实现生物识别身份验证:

<key>NSFaceIDUsageDescription</key>

但是,我遇到了一个错误。所以,我做了以下修改:

<key>NSFaceIDUsageDescription</key>
<string>Why is my app authenticating using face id?</string>  /* add */

为什么需要将文字括起来?

ios xml info.plist
1个回答
0
投票

Plist
文件是包含值作为键值对的文件。每个系统密钥都有不同的用途。即
UIMainStoryboardFile
确定
main.storyboard
等。在您的情况下,它用于许可请求,特别是生物识别。您必须为此密钥提供值,该值将显示为有关警报权限的消息。检查下面这个文件

https://developer.apple.com/library/content/documentation/General/Reference/InfoPlistKeyReference/Articles/CocoaKeys.html#//apple_ref/doc/uid/TP40009251-SW75

© www.soinside.com 2019 - 2024. All rights reserved.