-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
fix: backwards compatibility for types #8721
Merged
Merged
Changes from all commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
64e7987
fix:backwards compatibility for types
gtm-nayan 94522ee
update package json
gtm-nayan 26c5568
what an idiot
gtm-nayan c3730b8
replace SvelteComponentDev
gtm-nayan d6b7b24
work already
gtm-nayan ba3140d
remove indirection
gtm-nayan e9d9dec
this maybe?
gtm-nayan b52339b
hardcode directories
gtm-nayan fbe3ba5
would this do anything?
gtm-nayan 46c6c77
format
gtm-nayan d8a1bec
Revert "would this do anything?"
gtm-nayan a6c6fc5
Merge branch 'version-4' into types-backcompat
gtm-nayan e828216
no internal.d.ts
dummdidumm edc2ded
Merge branch 'version-4' into types-backcompat
dummdidumm 734bdd7
fix file endings
dummdidumm 0ad3db3
generate index signature manually
dummdidumm d067e2e
work around dts-buddy bug
dummdidumm d8570c2
simplify a bit
dummdidumm 0195883
changeset
dummdidumm File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'svelte': patch | ||
--- | ||
|
||
fix: ensure types are loaded with all TS settings |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'svelte': patch | ||
--- | ||
|
||
fix: export correct SvelteComponent type |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
declare module '*.svelte' { | ||
export { SvelteComponentDev as default } from 'svelte/internal'; | ||
export { SvelteComponent as default } from 'svelte'; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,27 @@ | ||
import './ambient.js'; | ||
|
||
// Types written in this particular order to work around a dts-buddy bug where it doesn't handle the | ||
// SvelteComponentDev as SvelteComponent alias correctly. | ||
// If that's fixed, we can do export * from './index.js' instead. | ||
|
||
export { | ||
SvelteComponent, | ||
SvelteComponentTyped, | ||
onMount, | ||
onDestroy, | ||
beforeUpdate, | ||
afterUpdate, | ||
setContext, | ||
getContext, | ||
getAllContexts, | ||
hasContext, | ||
tick, | ||
createEventDispatcher | ||
} from './index.js'; | ||
|
||
export type { | ||
ComponentConstructorOptions, | ||
ComponentEvents, | ||
ComponentProps, | ||
ComponentType | ||
} from './internal/public.js'; | ||
|
||
export * from './index.js'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,6 +9,7 @@ | |
|
||
"baseUrl": ".", | ||
"paths": { | ||
"svelte": ["."], | ||
"svelte/*": ["*"] | ||
}, | ||
"allowJs": true, | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What uses this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
vite plugin svelte and at least one other thing on the CI list
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should update them to use
svelte/compiler
as soon as v4 is out, so that these entry points can be dropped in v5