cleans up code
This commit is contained in:
@@ -8,12 +8,12 @@
|
||||
<link rel="icon" type="image/png" href="/favicon.png">
|
||||
</head>
|
||||
<body>
|
||||
<div id="results" style="font-size: x-large">
|
||||
</div>
|
||||
<div id="results" style="font-size: x-large"></div>
|
||||
<script type="module">
|
||||
function url() {
|
||||
return window.location.protocol + '//' + window.location.hostname + (window.location.port?.length > 0 ? ':' + window.location.port : '');
|
||||
}
|
||||
|
||||
const evtSource = new EventSource(url() + '/dice/{room}/results');
|
||||
evtSource.addEventListener('message', function (event) {
|
||||
let data = JSON.parse(event.data);
|
||||
|
||||
Reference in New Issue
Block a user