You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When using the dayjs library i get an error: __vite_ssr_import_1__.default is not a function
Logs
500
__vite_ssr_import_1__.default is not a function
TypeError: __vite_ssr_import_1__.default is not a function
at eval (/home/milln/projects/kit-temp/src/routes/index.svelte:11:44)
at Object.$$render (/home/milln/projects/kit-temp/node_modules/svelte/internal/index.js:1369:22)
at Object.default (root.svelte:46:46)
at /home/milln/projects/kit-temp/.svelte/dev/components/layout.svelte:5:41
at Object.$$render (/home/milln/projects/kit-temp/node_modules/svelte/internal/index.js:1369:22)
at root.svelte:42:13
at $$render (/home/milln/projects/kit-temp/node_modules/svelte/internal/index.js:1369:22)
at Object.render (/home/milln/projects/kit-temp/node_modules/svelte/internal/index.js:1377:26)
at get_response (file:///home/milln/projects/kit-temp/node_modules/@sveltejs/kit/dist/ssr.js:2326:27)
at async render_page (file:///home/milln/projects/kit-temp/node_modules/@sveltejs/kit/dist/ssr.js:2440:19)
To Reproduce
// src/routes/index.svelte
<scriptlang="ts">
importdayjsfrom"dayjs";const time =dayjs();
</script>
Expected behavior
the default import should work as expected
Severity
medium, i could use a different date library but i found this one is a really small and nice one
Additional context
I don't know if this issue is svelte kit related vite related.
I also turned on "allowSyntheticDefaultImports": true in tsconfig.json
The text was updated successfully, but these errors were encountered:
Describe the bug
When using the dayjs library i get an error:
__vite_ssr_import_1__.default is not a function
Logs
To Reproduce
Expected behavior
the default import should work as expected
Severity
medium, i could use a different date library but i found this one is a really small and nice one
Additional context
I don't know if this issue is svelte kit related vite related.
I also turned on
"allowSyntheticDefaultImports": true
intsconfig.json
The text was updated successfully, but these errors were encountered: