Closed blazzjosh closed 2 years ago
using with sveltekit...
Could you share some code that reproduces the bug, as well as the version of Svelte French Toast you’re using? Are you facing it during development or build, or both?
As a quick check, try installing Typescript and see if that fixes it.
the import line triggers this error- import toast, {Toaster} from 'svelte-french-toast'
I am using "svelte-french-toast": "^1.0.2", also not using typescript for my sveltekit installation -
Error: LoaderIcon
451/node_modules/.pnpm/svelte-french-toast@1.0.2_svelte@3.48.0/node_modules/svelte-french-toast/components/LoaderIcon.svelte at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15
These errors aren't enough to debug the issue, unfortunately. I need code (a repository or CodeSandbox/Glitch) that reproduces it.
Try installing Typescript, regardless of whether you're using it. I'm wondering if maybe it needs to be added as a peer dependency.
Okay, found the issue. Looks like Svelte recommends that packages that use Typescript (like this one) be transpiled to regular JS. Fix is in the works.
Fixed in 1.0.3. Upgrade your svelte-french-toast installation to the latest version to solve the issue.
Trying to use the lib - but on import error says - node_modules/svelte-french-toast/components/ToastIcon.svelte - Cannot find module 'typescript'