Skip to content

RN 0.56 - issue For components that can render Text #2187

@jenni-divvito

Description

@jenni-divvito

node, npm, react-native, react and native-base version

node v8.11.1, rn 0.56.0, react 16.4.1, NB 2.7.2

Expected behaviour

Able to pass strings directly to certain components, eg. `Text

Actual behaviour

Not able to do that - get a redbox error
Invariant Violation: Invariant Violation: Invariant Violation: Invariant Violation: Text strings must be rendered within a <Text> component.

Steps to reproduce should include code snippet and screenshot

attempt to reproduce, for example, the Form examples from the documentation on RN 0.56

Is the bug present in both iOS and Android or in any one of them?

Both

Any other additional info which would help us debug the issue quicker.

This is NOT a dupe of the earlier issue (#186) seen by some people with accidental characters from copying and pasting. This is an issue introduce in RN 0.56, and which is causing issues for some other libs (iyegoroff/react-native-text-gradient#11) too, See facebook/react#13211, which hopes to resolve the issue. Until then, not sure there's much NB can do about it, but putting it out there for anyone googling for the issue and so the NB team is aware of it.

That same library linked above have a temporary patch to remove the error in the meantime, too, on their github readme, https://github.com/iyegoroff/react-native-text-gradient#usage-with-rn--0560

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions