Reputation: 2261
Is it possible to change the color of a single word within a textinput in react native?
For example, when mentioning someone in a textinput when commenting:
Hello @user
I would like "@user" to be a different color than "Hello" already in the textinput. I know for <Text>
, it can be done with react-native-hyperlink
and linkify-it
, but this question concerns <TextInput>
Upvotes: 3
Views: 687
Reputation: 1989
Short Answer: No, it is not possible using the <TextInput/>
in React Native.
Your best bet would be using an input mask, something like react-native-text-input-mask
Upvotes: 1