From 1f398d2b082a0f36b070bb5dd8287ab6f855ae78 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Sat, 21 Oct 2023 21:18:12 +0200 Subject: dispatch domcontentloaded when trans done --- web/script/transition.ts | 1 + 1 file changed, 1 insertion(+) (limited to 'web/script') diff --git a/web/script/transition.ts b/web/script/transition.ts index 747ed70..5043c18 100644 --- a/web/script/transition.ts +++ b/web/script/transition.ts @@ -50,6 +50,7 @@ function prepare_load(href: string, back?: boolean) { const [head, body] = rt.split("")[1].split("") document.head.innerHTML = head document.body.outerHTML = body + globalThis.dispatchEvent(new Event("DOMContentLoaded")) fade(true) if (!back) window.history.pushState({}, "", href) patch_page() -- cgit v1.2.3-70-g09d2