--- import Search from "astro-pagefind/components/Search"; /** * In SSR mode use this instead: * * ```ts * export const prerender = false; * const q = Astro.url.searchParams.get("q") ?? undefined; * ``` */ const q = "astro"; --- <!doctype html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width" /> <title>astro-pagefind</title> </head> <body> <h1>Pre-filled Search</h1> <p>Searching for: {q}</p> <Search id="search" query={q} /> </body> </html>