【发布时间】:2019-05-28 19:06:20
【问题描述】:
我使用带有secureTextEntry 标志的TextInput 来允许用户输入他们的密码。当我运行tryLogin() 函数时,无论密码是否正确,iOS 都会询问用户是否要“记住浏览器上的密码”(类似于 Safari 的做法)。
有没有办法在 React Native 中禁用该对话框?
【问题讨论】:
-
你能分享你
TextInput的代码吗? -
是的,对不起,我太笨了:
<TextInput autoCapitalize="none" placeholderTextColor={appColors.lightGray} style={styles.input} autoCorrect={false} placeholder="Password" secureTextEntry={true} keyboardType="email-address" ref = {component => this.inputs.LIPass = component} returnKeyType="done" value={this.state.loginPass} textContentType="none" onChangeText={(pass) => this.setState({loginPass: pass})} />
标签: javascript ios react-native jsx