this shows how to build a Svelte component for the purposes of injecting into another page.
its forked from the default svelte app template with a few modifications you can find here https://github.com/sw-yx/dynamic-svelte-loading-demo/pull/1