This commit is contained in:
parent
aaa7a07849
commit
0610acbf6e
10 changed files with 134 additions and 41 deletions
|
|
@ -44,6 +44,10 @@ class Connection {
|
|||
}
|
||||
}
|
||||
|
||||
send(message) {
|
||||
this.socket.send(JSON.stringify(message));
|
||||
}
|
||||
|
||||
close() {
|
||||
this.socket.removeEventListener('open', this.onOpen);
|
||||
this.socket.removeEventListener('message', this.onMessage);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue