Skip to content

Instantly share code, notes, and snippets.

@deviantfero
Created January 31, 2018 17:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save deviantfero/e0cf24548dbd4429a9b0454da600f555 to your computer and use it in GitHub Desktop.
Save deviantfero/e0cf24548dbd4429a9b0454da600f555 to your computer and use it in GitHub Desktop.
type MatchMessage = {
type: MessageType.MATCHED
match: string
offer: boolean
}
type SDPMessage = {
type: MessageType.SDP
sdp: string
}
type ICEMessage = {
type: MessageType.ICE
candidate: string,
label: number,
id: string
}
type PeerLeft = {
type: MessageType.PEER_LEFT
}
type ClientMessage = MatchMessage
| SDPMessage
| ICEMessage
| PeerLeft
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment