-
-
Notifications
You must be signed in to change notification settings - Fork 116
refactor(types): use dts-buddy to generate types with map #751
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
Merged
Merged
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
27e81f8
refactor(types): use dts-buddy to generate types with map, cleanup ty…
dominikg b6f31dd
chore: update generated types
dominikg 415c907
fix: use .d.ts for type imports
dominikg 106ee52
fix: ignore .changesets/pre.json to prevent format check fails on mai…
dominikg ee08d94
Merge branch 'main' into types/dts-buddy
dominikg 809c8c2
fix: move types inside import condition to avoid masquerading as cjs …
dominikg ee005a6
fix: types
dominikg cda0ed1
Merge branch 'main' into types/dts-buddy
dominikg 3f6cd6a
bump dts-buddy
Rich-Harris 4543ff4
fix: regenerate types
dominikg b860137
fix: use correct type Options for plugin function arg
dominikg 26a7137
fix(types): reexport index.js from public.d.ts to ensure types and fu…
dominikg f4d6401
Merge branch 'main' into types/dts-buddy
dominikg 24a14e4
fix: update lockfile
dominikg 1cc0cc3
Update .changeset/metal-olives-wait.md
dominikg a42b619
Merge branch 'main' into types/dts-buddy
dominikg dfbc085
fix: update types
dominikg 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 hidden or 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 @@ | ||
--- | ||
'@sveltejs/vite-plugin-svelte': patch | ||
--- | ||
|
||
fix(types): use correct type Options for svelte function arg |
This file contains hidden or 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 @@ | ||
--- | ||
'@sveltejs/vite-plugin-svelte': major | ||
--- | ||
|
||
breaking: remove package.json export |
This file contains hidden or 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,6 @@ | ||
--- | ||
'@sveltejs/vite-plugin-svelte-inspector': major | ||
'@sveltejs/vite-plugin-svelte': major | ||
--- | ||
|
||
breaking(types): emit types with dts-buddy to include type map |
This file contains hidden or 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 @@ | ||
--- | ||
'@sveltejs/vite-plugin-svelte': major | ||
--- | ||
|
||
breaking(types): rename SvelteOptions to SvelteConfig |
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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,21 +1,17 @@ | ||
{ | ||
"include": ["src"], | ||
"exclude": ["**/*.spec.ts"], | ||
"compilerOptions": { | ||
"noEmit": true, | ||
"target": "ES2020", | ||
"module": "ES2020", | ||
"module": "ES2022", | ||
"moduleResolution": "node", | ||
"strict": true, | ||
"declaration": true, | ||
"sourceMap": true, | ||
"noUnusedLocals": true, | ||
"esModuleInterop": true, | ||
"baseUrl": ".", | ||
"resolveJsonModule": true, | ||
// see https://devblogs.microsoft.com/typescript/announcing-typescript-4-4-beta/#use-unknown-catch-variables | ||
"useUnknownInCatchVariables": false, | ||
"allowJs": true, | ||
"checkJs": true | ||
"checkJs": true, | ||
"allowSyntheticDefaultImports": true | ||
} | ||
} |
This file contains hidden or 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,74 @@ | ||
declare module '@sveltejs/vite-plugin-svelte-inspector' { | ||
export interface Options { | ||
/** | ||
* define a key combo to toggle inspector, | ||
* @default 'meta-shift' on mac, 'control-shift' on other os | ||
* | ||
* any number of modifiers `control` `shift` `alt` `meta` followed by zero or one regular key, separated by - | ||
* examples: control-shift, control-o, control-alt-s meta-x control-meta | ||
* Some keys have native behavior (e.g. alt-s opens history menu on firefox). | ||
* To avoid conflicts or accidentally typing into inputs, modifier only combinations are recommended. | ||
*/ | ||
toggleKeyCombo?: string; | ||
|
||
/** | ||
* define keys to select elements with via keyboard | ||
* @default {parent: 'ArrowUp', child: 'ArrowDown', next: 'ArrowRight', prev: 'ArrowLeft' } | ||
* | ||
* improves accessibility and also helps when you want to select elements that do not have a hoverable surface area | ||
* due to tight wrapping | ||
* | ||
* A note for users of screen-readers: | ||
* If you are using arrow keys to navigate the page itself, change the navKeys to avoid conflicts. | ||
* e.g. navKeys: {parent: 'w', prev: 'a', child: 's', next: 'd'} | ||
* | ||
* | ||
* parent: select closest parent | ||
* child: select first child (or grandchild) | ||
* next: next sibling (or parent if no next sibling exists) | ||
* prev: previous sibling (or parent if no prev sibling exists) | ||
*/ | ||
navKeys?: { parent: string; child: string; next: string; prev: string }; | ||
|
||
/** | ||
* define key to open the editor for the currently selected dom node | ||
* | ||
* @default 'Enter' | ||
*/ | ||
openKey?: string; | ||
|
||
/** | ||
* inspector is automatically disabled when releasing toggleKeyCombo after holding it for a longpress | ||
* @default true | ||
*/ | ||
holdMode?: boolean; | ||
|
||
/** | ||
* when to show the toggle button | ||
* @default 'active' | ||
*/ | ||
showToggleButton?: 'always' | 'active' | 'never'; | ||
|
||
/** | ||
* where to display the toggle button | ||
* @default top-right | ||
*/ | ||
toggleButtonPos?: 'top-right' | 'top-left' | 'bottom-right' | 'bottom-left'; | ||
|
||
/** | ||
* inject custom styles when inspector is active | ||
*/ | ||
customStyles?: boolean; | ||
|
||
/** | ||
* internal options that are automatically set, not to be set or used by users | ||
* */ | ||
__internal?: { | ||
// vite base url | ||
base: string; | ||
}; | ||
} | ||
export function svelteInspector(options?: Partial<Options> | undefined): import('vite').Plugin; | ||
} | ||
|
||
//# sourceMappingURL=index.d.ts.map |
17 changes: 17 additions & 0 deletions
17
packages/vite-plugin-svelte-inspector/types/index.d.ts.map
This file contains hidden or 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,17 @@ | ||
{ | ||
"version": 3, | ||
"file": "index.d.ts", | ||
"names": [ | ||
"Options", | ||
"svelteInspector" | ||
], | ||
"sources": [ | ||
"../src/public.d.ts", | ||
"../src/index.js" | ||
], | ||
"sourcesContent": [ | ||
null, | ||
null | ||
], | ||
"mappings": ";kBAAiBA,OAAOA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBCoBRC,eAAeA" | ||
} |
This file contains hidden or 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 hidden or 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 hidden or 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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.