How to access f7router from main svelte App component

I am able to get a handle on the f7router from within a Svelte view component as the document mentions here:

  // Router component will receive f7router prop with current Router instance
  export let f7router;
  // Router component will receive f7route prop with current route data
  export let f7route;

How would I get access to the f7router from the main App component that contains the routes/views?

In case it’s helpful for anyone, here is how I did it:

import { onMount } from 'svelte';
import { f7ready } from 'framework7-svelte';
let f7router;

onMount(() => {
  f7ready((f7) => {
    f7router = f7.views.main.router;