From c5380f601ff60132aa57d50061a921064ee74495 Mon Sep 17 00:00:00 2001 From: tdro Date: Fri, 14 Apr 2023 16:36:28 -0400 Subject: static/js/timeago.ts: load -> DOMContentLoaded --- assets/js/index.js | 2 +- static/js/timeago.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/assets/js/index.js b/assets/js/index.js index 1e267b9..fc1f6c3 100644 --- a/assets/js/index.js +++ b/assets/js/index.js @@ -587,7 +587,7 @@ } }; const substitution = setInterval(date, 4); - self.addEventListener("load", function() { + self.addEventListener("DOMContentLoaded", function() { setTimeout(function() { clearInterval(substitution); setInterval(date, 1000); diff --git a/static/js/timeago.ts b/static/js/timeago.ts index f7567ed..81ae579 100644 --- a/static/js/timeago.ts +++ b/static/js/timeago.ts @@ -47,7 +47,7 @@ const substitution = setInterval(date, 4); - self.addEventListener("load", function () { + self.addEventListener("DOMContentLoaded", function () { setTimeout(function () { clearInterval(substitution); setInterval(date, 1000); -- cgit v1.2.3