if (performance.navigation.type === 1) { // Page was refreshed, no action needed } else { // Append a unique query string to force cache refresh const currentUrl = window.location.href; const newUrl = currentUrl.includes('?') ? `${currentUrl}&cache_bust=${new Date().getTime()}` : `${currentUrl}?cache_bust=${new Date().getTime()}`; window.location.href = newUrl; }
Skip to content