Skip to content

Commit

Permalink
SPIN-126 // Adjust the script delays
Browse files Browse the repository at this point in the history
  • Loading branch information
MVogge committed Dec 12, 2023
1 parent 54d1dda commit 07fcd1c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion scripts/delayed.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@ import { initializeHubspot } from '../blocks/form/form.js';
// Core Web Vitals RUM collection
sampleRUM('cwv');
injectStarsLayers();
initializeHubspot();
setTimeout(() => {
initializeHubspot();
}, 2000);

/* IMPORTANT: this is just for fun and not actually used. Please ignore this :) */
let lastKeys = '';
Expand Down
2 changes: 1 addition & 1 deletion scripts/scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ async function loadLazy(doc) {
*/
function loadDelayed() {
// eslint-disable-next-line import/no-cycle
window.setTimeout(() => import('./delayed.js'), 3000);
window.setTimeout(() => import('./delayed.js'), 2000);
// load anything that can be postponed to the latest here
}

Expand Down

0 comments on commit 07fcd1c

Please sign in to comment.