Skip to content
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

(feat) Add support for svelte-jsx.d.ts and svelte-native-jsx.d.ts to emitDts #1405

Closed
wants to merge 1 commit into from

Conversation

rgossiaux
Copy link

The svelte.JSX namespace, and in particular the svelte.JSX.HTMLAttributes interface, is used by several component libraries. But SvelteKit's package command will fail for components that use them because these definitions are missing. See kit#3783

…emitDts

The svelte.JSX namespace, and in particular the svelte.JSX.HTMLAttributes interface, is used by several component libraries. But SvelteKit's package command will fail for components that use them because these definitions are missing. See kit#3783
@@ -5,6 +5,8 @@ import { svelte2tsx } from './svelte2tsx';
export interface EmitDtsConfig {
declarationDir: string;
svelteShimsPath: string;
svelteJsxPath?: string;
svelteNativeJsxPath?: string;
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another option is adding a [string] option for additional paths instead of just listing these out individually, and another alternative is emitDts just finding & reading these itself (I wasn't sure why it's structured this way right now). Another option is combining all of the declarations into one file.

Obviously you folks would know best, I just opened this PR to get the ball rolling.

dummdidumm pushed a commit to dummdidumm/language-tools that referenced this pull request Mar 14, 2022
Needed when someone uses the svelte.JSX typings.
Closes sveltejs#1405
@dummdidumm dummdidumm marked this pull request as draft March 14, 2022 16:01
@dummdidumm
Copy link
Member

Closing as the svelte.JSX namespace is now deprecated

@dummdidumm dummdidumm closed this Dec 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants