-
Notifications
You must be signed in to change notification settings - Fork 25.1k
Closed
Labels
Ran CommandsOne of our bots successfully processed a command.One of our bots successfully processed a command.Resolution: For Stack OverflowA question for Stack Overflow. Applying this label will cause issue to be closed.A question for Stack Overflow. Applying this label will cause issue to be closed.Resolution: LockedThis issue was locked by the bot.This issue was locked by the bot.
Description
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
While I'm using FlatList in my code, I'm getting this error. If I remove the FlatList code, the app is working fine. I imported FlastList in my code too and I'm export the container.
import { ListView, Text, FlatList } from 'react-native';
render() {
return (
<FlatList
data={[{ key: 'a' }, { key: 'b' }]}
renderItem={({ item }) => <Text>{item.key}</Text>}
/>
);
}
export default connect(mapStateToProps, mapDispatchToProps)(HistoryViewport);
Please give some solution, where I'm doing mistake! What I forgot to export the component from the file?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Ran CommandsOne of our bots successfully processed a command.One of our bots successfully processed a command.Resolution: For Stack OverflowA question for Stack Overflow. Applying this label will cause issue to be closed.A question for Stack Overflow. Applying this label will cause issue to be closed.Resolution: LockedThis issue was locked by the bot.This issue was locked by the bot.
