title: How do get query string parameter in sveltekit?
body: <p>I'm trying to the <code>/login?ref=/some/path</code> parameter to redirect to after login:</p>
  <pre><code>    const ref = $page.url.searchParams.get('ref') || '/dashboard';
  </code></pre>
  <p>However I get this error:</p>
  <p><code>TypeError: Cannot read properties of undefined (reading 'searchParams')</code></p>