I am trying to break lines of text with automatic hyphenation in Android with react-native. It is an important feature for some languages. For example for Russian and it's typography. In Russian words are longer than in English so they should be wrapped with hyphenation to create a straight right text border.
I tryied to follow suggestions in this question: Hyphenation in Android
I added soft hyphens in places where words can be splitted. But Android still wrap lines only at spaces. Then I replaced all the spaces with non-breaking spaces. And it works, until a word is not longer than 45 letters. As all my spaces are non-breakable Android treats all the text as a single word, so if it is more than 45 letters it is not hyphened.
Here is a screenshot with the problem. All the spaces are replaced with non-breaking spaces. First paragraph is longer than 45 letters so android break lines at any position (not at soft hyphens). Second paragraph is cropped to 45 letters and you can see the desired behavior there.
My setup:
npm dependencies:
"expo": "21.0.0"
"react-native": "0.48.4"
"react": "16.0.0-alpha.12"
app.json
"sdkVersion": "21.0.0"
Android-7.1.1, Expo-1.20 (Android application)