i want to using Typing Indicator from Gifted Chat, here is my code to show typing state:
const [isTyping, setIsTyping] = useState(false)
const renderFooter = (props) => {
return <TypingIndicator isTyping={isTyping}/>
}
<GiftedChat>
....
renderFooter={renderFooter}
isTyping={isTyping}
onPressAvatar={() => {
console.log('longpressavt', isTyping)
setIsTyping(!isTyping)
}}
</GiftedChat>
i can show typing indicator in first avatar click, but next time click the Typing Indicator does not dismiss, can anyone guide me to know problem? Thanks
Try this: -
shouldUpdateMessage={() => { return true; }}
I got it from this link - https://github.com/FaridSafi/react-native-gifted-chat/issues/2186