-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Description
On "Providing you own html" you can instead of asking to put the script tag with the code, you could serve yourself from the code the script code:
const sse = new EventSource("/refresh/v1/sse");
sse.addEventListener("message", (e) => {
const msg = JSON.parse(e.data);
if ("KeepAlive" in msg) console.log("KeepAlive");
if ("PageRefresh" in msg) location.reload();
});
in a special path..
Like:
/script/live-server.js
And then ask the users to add:
<script src="/scripts/live-server.js" />
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels