with props: <Loadable component={Component} some="value" />
with page loader: <Loadable loader={() => getComponentDynamically()} />
with registered loader: <Loadable loader={register({ loader, resolve })} />
with default and loading slot: <Loadable ...><div slot="loading">loading...</div>...</Loadable>
others...but those ^ would be a good start
Could use cypress and cypress-svelte-unit-test. Or the test library that svelte itself uses. Or whatever the implementer's heart desires, so long as it asserts what needs to be asserted :)
I may get to this at some point, but wanted to note it in case you're already working on it.
Some cases (not exhaustive):
<Loadable component={Component} />
<Loadable component={Component} some="value" />
<Loadable loader={() => getComponentDynamically()} />
<Loadable loader={register({ loader, resolve })} />
<Loadable ...><div slot="loading">loading...</div>...</Loadable>
Could use cypress and cypress-svelte-unit-test. Or the test library that svelte itself uses. Or whatever the implementer's heart desires, so long as it asserts what needs to be asserted :)