json docs

This commit is contained in:
lovasoa
2024-10-23 15:20:54 +02:00
parent 38d6e5f058
commit 57681a54cb
@@ -152,6 +152,9 @@ eventSource.onmessage = function (event) {
const user = JSON.parse(event.data);
console.log(user.username);
}
eventSource.onerror = function () {
eventSource.close(); // do not reconnect after reading all the data
}
```
'
);