Disable Options on React-Native Text Input
You should add 2 attributes
selectTextOnFocus
and editable
For example:
<TextInput editable={false} selectTextOnFocus={false} />
Just give your textinput the attribute editable={false}
contextMenuHidden is to disable the user from pasting text into certain fields and to hide context menu.
Update: This hasn’t been included in a release yet. You can always see what release any commit is in by clicking on the link and looking at the tags. so I wouldn't expect it to be on a stable release until 0.55.
<TextInput contextMenuHidden={true} />
Check the commit here: Add option to hide context menu for TextInput
Set pointerEvents to none on parent View
of TextInput
to disable touch events, consider following example:
<View pointerEvents="none">
<TextInput ... />
</View>