Skip to content

TextInput briefly displays restricted characters before validation removes them when using onChangeText #47252

@rvmaher

Description

@rvmaher

Description

Hi there,
Just wanted to bring up an issue that many of us have come across. When using TextInput with validation in onChangeText, restricted text still flashes for a moment before it gets removed. This is a pretty common need in apps, where real-time validation is used to guide user input (like blocking specific characters or setting a format). But right now, seeing those restricted characters pop up briefly makes the input feel a bit off.
There are many Workarounds and hacks for this but don’t quite fix the experience entirely. Is there any chance this could be smoothed out natively in the future?

Steps to reproduce

Screenshot 2024-10-28 at 18 10 02

React Native Version

0.76.0

Affected Platforms

Runtime - Android, Runtime - iOS

Output of npx react-native info

Not needed

Stacktrace or Logs

Not needed

Reproducer

https://snack.expo.dev/fVO2DXQPPqQVlm9QBZ2ms

Screenshots and Videos

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Component: TextInputRelated to the TextInput component.Issue: Author Provided ReproThis issue can be reproduced in Snack or an attached project.Needs: AttentionIssues where the author has responded to feedback.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions