leecade / leecade/react-native-swiper
Text strings must be rendered within a <Text> component
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 10.5k
- Forks
- 2.3k
- PR merge metrics
- No merged PRs in 30d
Description
If you pass children with prop title inside Swiper you will get this error Text strings must be rendered within a <Text> component. That because of this terrible line of code https://github.com/leecade/react-native-swiper/blob/master/src/index.js#L702
It is just so wrong solution to reserve prop title for a package assuming that people are not using prop title in items that they pass to to the package, because this is very common property name to use.
I face this crash once a half of year and every time forget about this terribly written line of code. Leaving this issue here in case I forget again, of anyone else face it
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at src/index.js line 702 and reproduce the crash by passing a Swiper item with a title prop as children. Trace how that prop is handled, then verify that title remains usable without the Text strings error and run the project's existing checks.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, react-native
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100