-
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Missing dependencies in svelte/compiler type definitions #3397
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Is there a way to fix this by adding the types as dependencies, but not the packages? |
I've made an attempt in a new PR referenced above. I believe it's not very robust, but I could not find any other way to do that. I looked for a way to make Typescript bundle included files, but didn't find anything. |
The issue is closed, but this still fails for me ... Here was my workaround to overcome this trouble |
Issue reoccurs because while merging #3539 the bug was reintroduced because the fix was undone: b9f1484#diff-ff6e5f22a9c7e66987b19c0199636480 . I also think just reimplementing the fix will not work anymore. If the typings should be included in svelte it would mean including all of |
Any news on this or is there a different issue tracking the bug? |
@Rich-Harris I think this rollup plugin can resolve this problem. |
Describe the bug
When compiling a Typescript code that uses
svelte/compile
, it fails because of missing libraries inside Svelte package.Logs
To Reproduce
npm init -y
at empty foldernpm i -D svelte typescript
test.ts
with the following import:import * as svelte from 'svelte/compiler'
npx tsc
Expected behavior
I should not need to manually install Svelte's dependencies; compilation should not fail.
Information about your Svelte project:
Severity
Annoying. I can manually install Svelte's dependencies into my project.
The text was updated successfully, but these errors were encountered: