dsh-unlag 1.9.63 → 1.9.64
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/client.js +16 -3
- package/package.json +1 -1
package/client.js
CHANGED
|
@@ -564,9 +564,22 @@ window.__ModuleLoader__.load({
|
|
|
564
564
|
function reloadFreshPage() {
|
|
565
565
|
const graph = window.__DSH_BOOT__;
|
|
566
566
|
const stamp = typeof graph?.rev === 'string' && graph.rev !== '' ? graph.rev : String(Date.now());
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
567
|
+
// The address is the page's own; a document whose address cannot be parsed still has to come
|
|
568
|
+
// back as a fresh one, because the code behind it has already been replaced.
|
|
569
|
+
let target = null;
|
|
570
|
+
try {
|
|
571
|
+
const parsed = new URL(location.href);
|
|
572
|
+
parsed.searchParams.set('interface', stamp);
|
|
573
|
+
target = parsed.toString();
|
|
574
|
+
} catch {
|
|
575
|
+
target = null;
|
|
576
|
+
}
|
|
577
|
+
try {
|
|
578
|
+
if (target !== null) window.location.replace(target);
|
|
579
|
+
else window.location.reload?.();
|
|
580
|
+
} catch {
|
|
581
|
+
// The page is going away either way; the press has already reported what it replaced.
|
|
582
|
+
}
|
|
570
583
|
}
|
|
571
584
|
|
|
572
585
|
/** A window the user still has open would go away with the rebuild. */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-unlag",
|
|
3
|
-
"version": "1.9.
|
|
3
|
+
"version": "1.9.64",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A press applies plugin edits right away and brings a laggy interface back; automatic reloading stays off unless you turn it on, so the press is the only trigger, and nothing restarts.",
|
|
6
6
|
"license": "MIT",
|