Closed Luckygirlllll closed 5 years ago
hey man o/, use the type custom
to create custom phone masks.
https://github.com/benhurott/react-native-masked-text#custom
@benhurott awesome, it works!
<TextInputMask
style={styles.input}
placeholder='Phone*'
type={'custom'}
value={this.state.international}
options={{
mask: '(999) 999-9999'
}}
onChangeText={text => {
this.setState({
international: text
})
}}
></TextInputMask>
I'm creating custom mask to cell phone, how can I limit max length to 10 symbols, fo example?
Here is my code: