Skip to content

Element type is invalid #9

@armnotstrong

Description

@armnotstrong

Hey, trying to use react-native-hr in my project as this:

import {Hr} from 'react-native-hr'
    ...
    class MyListItem extends PureComponent {
 render(){
   return (
     <View style={styles.detailCard}>
     

         <Text style={styles.detailCardContent}>{this.props.content}</Text>
         <Hr />
         <Text> --{this.props.re}</Text>
         <Text>=====================</Text>
         </View>
     );
 }

}

But above code gives me an error:

Warning: React.createElement: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions