React Native Password TextInput抛出警告

Qud*_*oos 8 react-native

我有一个TextInput字段,我想用于密码

<TextInput secureTextEntry="true"></TextInput>
Run Code Online (Sandbox Code Playgroud)

但我一直在iOS模拟器和chrome调试工具中收到此警告

Failed propType: Invalid prop `secureTextEntry` of type `string` supplied to `TextInput`, expected `boolean`.
Run Code Online (Sandbox Code Playgroud)

我在"反应原生":"^ 0.16.0"

Nad*_*bit 15

试试这个:

<TextInput secureTextEntry={ true }></TextInput>
Run Code Online (Sandbox Code Playgroud)