entria / react-native-fontawesome

React Native Font Awesome Icons
MIT License
176 stars 34 forks source link

Red screen error when trying to use lib #13

Open ciceroneves opened 7 years ago

ciceroneves commented 7 years ago

Hi I have a function that takes a parameter named description and returns the following:

return (
        <View style={ Styles.cardGroupHeader }>
          <Text style={ Styles.cardGroupHeaderText }>No { description }</Text>
          <Text>
            <FontAwesome>{ Icons.chevronRight }</FontAwesome>
          </Text>
        </View>
    );

When I run my code I get a red screen error with the following error message: Layout: -1 < 0

If I remove

<Text>
  <FontAwesome>{ Icons.chevronRight }</FontAwesome>
</Text>

The code works fine.

Any ideas on how to solve it? I only imported the package and tried to use the component. I haven't followed the instructions of this link https://medium.com/@gattermeier/custom-fonts-in-react-native-for-android-b8a331a7d2a7

Are those steps required?

Thanks

rturk commented 7 years ago

Hi @ciceroneves are you sure that you've installed the source font in your project? Looks like that the font is missing in the build