From 65c210f405f158771dbb252419fd0c8774bdb01a Mon Sep 17 00:00:00 2001 From: bosco-ensemble Date: Tue, 9 Apr 2024 12:10:41 -0700 Subject: [PATCH] TDW-2277 called loadDependencies in loadPAge --- scripts/scripts.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/scripts.js b/scripts/scripts.js index db25871d..c877c5ad 100644 --- a/scripts/scripts.js +++ b/scripts/scripts.js @@ -709,6 +709,8 @@ async function loadPage(doc) { await loadEager(doc); // eslint-disable-next-line no-use-before-define await loadLazy(doc); + // eslint-disable-next-line import/no-cycle + loadDependencies(); // eslint-disable-next-line no-use-before-define loadDelayed(doc); } @@ -1069,8 +1071,6 @@ async function loadLazy(doc) { addFavIcon(`${window.hlx.codeBasePath}/styles/favicon.ico`); doc.querySelectorAll('div:not([class]):not([id]):empty').forEach((empty) => empty.remove()); - // eslint-disable-next-line import/no-cycle - loadDependencies(); } /** @@ -1085,7 +1085,7 @@ function loadDelayed() { function loadDependencies() { // eslint-disable-next-line import/no-cycle - window.setTimeout(() => import('./dependencies.js'), 1000); + window.setTimeout(() => import('./dependencies.js'), 500); } export async function lookupPages(pathnames) {