1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
<script lang="ts"> import { page } from '$app/state'; import { onDestroy, onMount } from 'svelte'; let mounted = $state(false); onMount(() => (mounted = true)); onDestroy(() => (mounted = false)); </script> <svelte:head> {#if !mounted} <noscript> <meta http-equiv="refresh" content="5; url={page.url.href}" /> </noscript> {/if} </svelte:head>