-
-
Save adelowo/ad6311c01ca681514dfb238413d68154 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, {Component} from 'react'; | |
import {SafeAreaView, View} from 'react-native'; | |
import { | |
Chat, | |
Channel, | |
MessageList, | |
MessageInput, | |
} from 'stream-chat-react-native'; | |
export default class ChatView extends Component { | |
state = { | |
isReady: false, | |
}; | |
render() { | |
const channel = this.props.chatClient.channel( | |
'messaging', | |
'lambda-webhook-chat', | |
{ | |
name: 'Webhook server', | |
} | |
); | |
return ( | |
<Chat client={this.props.chatClient}> | |
<Channel channel={channel}> | |
<View style={{display: 'flex', height: '100%'}}> | |
<MessageList /> | |
<MessageInput /> | |
</View> | |
</Channel> | |
</Chat> | |
); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment