Skip to content

Commit

Permalink
Adhere closer to MessageEvent
Browse files Browse the repository at this point in the history
  • Loading branch information
backkem committed Dec 22, 2023
1 parent 71d142a commit b36f1e2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion EXPLAINER.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ conn.ondatachannel = (e) => {
const channel = conn.createDataChannel("My Channel");

channel.onmessage = (e) => {
console.log(`Receiver: Received message: ${e.message}`);
console.log(`Receiver: Received message: ${e.data}`);
};
```

Expand Down
2 changes: 1 addition & 1 deletion index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -632,7 +632,7 @@ receiver.onconnection = e => {
const channel = e.channel;

channel.onmessage = e => {
const message = e.message;
const message = e.data;
console.log(\`Receiver: Received message: ${message}\`);
};

Expand Down

0 comments on commit b36f1e2

Please sign in to comment.