Allow passing ref to Text component in Ignite boilerplate #2758
Please verify the following:
- [x]
yarn testjest tests pass with new tests, if relevant - [x]
yarn linteslint checks pass with new code, if relevant - [x]
yarn format:checkprettier checks pass with new code, if relevant - [x]
README.md(or relevant documentation) has been updated with your changes
Describe your PR
This PR allows passing ref to the Text component in boilerplate.
Have added the feature and a demo in Demo Community Screen.
@frankcalise Let me know if I need to add something or if things need to be moved around.
This fixes #2758
Hi @Aniganesh!
For understanding your PR and improving documentation, could you let us know your use case for forwarding the Text ref?
Hey! Extremely sorry for not responding for this long. The use case for this was that I had to position a bunch of <Text /> components and also adjust their positioning based on their heights. Initially I used refs and then called measure() on the refs. That's when I got the idea for the PR. Later, I realized my purpose is better served with the onLayout callback and went with that instead. Thought I'd still add the PR in case anyone has a similar purpose and wants to use refs.
Once again, apologies for not responding for so long.
@Aniganesh are you still interested in resolving the conflicts here or should we close this?