Inconsistent text behavior in TextInput between iOS and Android
See original GitHub issueIs this a bug report?
Yes
Have you read the Bugs section of the Contributing to React Native Guide?
Yes
Environment
react-native -v
:
react-native-cli: 2.0.1
react-native: 0.45.1
(edit: it reproduces in 0.54.2 according to the comments -@hramos)
node -v
:v7.7.2
npm -v
:4.1.2
yarn --version
(if you use Yarn):N/A
Then, specify:
- Target Platform (e.g. iOS, Android): Android
- Development Operating System (e.g. macOS Sierra, Windows 10): macOS Sierra 10.12.5
- Build tools (Xcode or Android Studio version, iOS or Android SDK version, if relevant): Android Studio 2.3.2. Compile SDK 23. Build tools 23.0.1
Steps to Reproduce
- Create a TextInput that fits 100% width of the screen
- Set the TextInput’s
value
to a string that will render larger than the width of the text view - Run in Android and note which part of the string renders
- Run in iOS and note which part of the string renders
Expected Behavior
Both iOS and Android should exhibit the same behavior and display the beginning of the text when unfocused.
Ideally, the ellipsis should also be an optional parameter to display when unfocused on both Android and iOS.
Actual Behavior
iOS displays the beginning of the text, ellipsizing the remaining text before truncating.

Android displays the end of the text with no ellipsis at the beginning.

Reproducible Demo
Example project: https://snack.expo.io/S1Lty1oN- To view the issue, launch the example project and preview in Android. Then preview in iOS. Note the differences between where ellipsis show and which part of the sentence displays.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:32
- Comments:36 (2 by maintainers)
Top Results From Across the Web
React-native TextInput different behaviour on Android platform
I need to get rid of blinking text cursor but detect when users touches input. As it turns out on IOS platform works...
Read more >Inconsistent Text behavior in CarPlay - Apple Community
Ever since the latest update, I have seen weird and inconsistent behaviors in the Carplay txt app -- the Audi (and several other...
Read more >EditableText class - widgets library - Flutter - Dart API docs
Many TextInputActions are common between Android and iOS. ... Intent Class, Default Behavior when there's selected text, Default Behavior when there is a ......
Read more >The Textarea element - HTML: HyperText Markup Language
The HTML element represents a multi-line plain-text editing control, ... in <input>: The Input (Form Input) element for a full explanation.
Read more >TextInput - React Native
Note that on Android performing text selection in an input can change the app's activity windowSoftInputMode param to adjustResize . This may ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
This issue is still going strong in
0.63.4
0.57.1 still having this issue. Very sad behavior if we have a long text in Android.