1

I am wanting to implement a custom text wrap strategy for my application running 0.59.9. There are portions of the app where time ranges are used (ex. '9/12/2019 8:00 AM - 10:00 AM EST') and especially on smaller devices or users with larger font scaling none of the baked in textWrap / numberOfLines options can handle quite what I want.

I would like it to break at a specified location, specifically the '-' in the timestamp. Is there a way to do this? Maybe a listener exists for isViewOverflowed that a developer can hook into?

1 Answer 1

1

One solution could be to break apart the string into two parts and just have a Text container which flows inline if there's enough space. Otherwise it will overflow.

<Text>
  <Text>9/12/2019 8:00 AM</Text>
  <Text>10:00 AM EST</Text>
</Text>
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.