-
Notifications
You must be signed in to change notification settings - Fork 223
Description
<OTPInputView
style={{
width: '100%',
height: 50,
alignSelf: 'center',
marginBottom: 20,
}}
pinCount={6}
code={(this.state.code)} //You can supply this prop or not. The component will be used as a controlled / uncontrolled component respectively.
onCodeChanged = {code =>{ if (code.length === 6) { { this.setState({code},()=>{ console.log('codeotp',this.state.code); })}}}}
autoFocusOnLoad={false}
keyboardType="number-pad"
codeInputFieldStyle={{
width: 32,
height: 45,
borderWidth: 2,
alignSelf: 'center',
borderRadius: 5,
color: color.secondarycolor,
}}
codeInputHighlightStyle={{
borderColor: color.secondarycolor,
}}
onCodeFilled={code => {
console.log(`Code is ${code}, you are good to go!`);
}}
// placeholderTextColor={{color:color.primarycolor}}
/>``
I'm getting this, issue when I want to pass default value to otp , I need to add default value for getting autofill otp by hash code sms
