Weird Text Component Issue on Android - React Native

56 views Asked by At

Hello fellow developers, I've encountered a peculiar issue with a React Native text component that's been giving me some trouble on certain Android devices (so far, Xiaomi devices). I'm hoping someone can shed some light on this. I have a text component in my React Native app, and it seems to be displaying an odd element at the end of the text string on some Android devices (so far, it's been limited to Android). It almost looks like a cluster of bars or lines, possibly an icon.

It's pretty straightforward, with a numberOfLines prop set to 2. The issue only occurs on some Android devices, and I can't quite figure out why. Has anyone else encountered something similar, or does anyone have an idea of what might be causing this strange artifact to appear at the end of the text? Any insights, suggestions, or debugging tips would be greatly appreciated. Thanks in advance for your help!

react: 18.0.0 => 18.0.0 react-native: 0.69.9 => 0.69.9

screenshot

What I Tried: I implemented a React Native text component with the numberOfLines prop set to 2.

Expected Outcome: I expected the text to be truncated after two lines, with no additional elements or artifacts displayed at the end of the string.

Actual Result: On some Android devices, the text component displays an unexpected element at the end of the text, resembling a series of bars or lines. This behavior is not consistent and occurs intermittently on certain Android devices.

0

There are 0 answers