## Demo: view-transitions ### PageOne.svelte ```svelte ``` ### PageTwo.svelte ```svelte ``` ### TransitionCard.svelte ```svelte
Page {page}

Each navigation is a full page load — the browser animates it with a {type} transition.

Transition: {#each TRANSITIONS as opt (opt)} {opt} {/each}
``` ### PersistentVideo.svelte ```svelte

Music: Traditional Japanese 2 — Bounce-Bay-Records

{@html persistentVideoScript} ``` ### persistent.js ```ts // Rendered into the page via {@html} in PersistentVideo.svelte, so it runs on initial parse of every // page — including after a cross-document navigation — resuming the video with no hydration bundle. // The closing script tag is split across concatenation here rather than assembled in the .svelte file, // since a literal one there would close that file's own script block early. export const persistentVideoScript = `