-
-
Save Teepheh-Git/0bb56e4e8d68c80dc43d08047eb0b98c to your computer and use it in GitHub Desktop.
This file contains hidden or 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
const readReceipt = async () => { | |
const readMessage = () => { | |
if (!socketRef.current) { | |
return; | |
} | |
socketRef.current.emit('readMessage', {message_id: '1', user_id: '7'}); | |
}; | |
}; | |
const sendMessage = url => { | |
if (!socketRef.current) { | |
return; | |
} | |
socketRef.current.emit('sendMessage', { | |
user_id: user.id, | |
message_text: myMessage, | |
audio_file: 'null', | |
image_url: url, | |
group_id: groupId, | |
}); | |
setMyMessage(''); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment