A sample for react-native-pin-input
npm install --save react-native-pin-input
or
yarn add react-native-pin-input
set keyboardType
<PinInput
ref={"pin"}
pinLength={6}
value={'654321'}
autoFocus={false}
pinItemStyle={{width: 50, height: 50}}
pinItemProps={{keyboardType:'number-pad'}}
onPinCompleted={(pin) => {
this.setState({pin: pin})
}}
/>
this.refs.pin.setPin('123456')
const pin = this.refs.pin.getPin()
this.refs.pin.clearPin()
this.refs.pin.focusPin(0)