Skip to content

feat: zero-config +error.svelte props#3076

Merged
dummdidumm merged 2 commits into
masterfrom
zero-config-error-types
Jul 8, 2026
Merged

feat: zero-config +error.svelte props#3076
dummdidumm merged 2 commits into
masterfrom
zero-config-error-types

Conversation

@Rich-Harris

Copy link
Copy Markdown
Member

No idea if I'm doing this right, but: this should allow zero-config types for the error prop passed to an +error.svelte file:

<script>
  let { error } = $props(); // error is typed as `App.Error`
</script>

<h1>oops: {error.message}</h1>

I thought we'd need to do sveltejs/kit#16272 first, but I'm not sure it's all that helpful since we'd need to be careful about the version. As it stands, this would allow someone to create the above props declaration with a version of SvelteKit that didn't pass error to the component, but that's probably fine?

@changeset-bot

changeset-bot Bot commented Jul 8, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: d896d57

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
svelte2tsx Patch
svelte-check Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@dummdidumm dummdidumm left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

👍

Comment thread .changeset/grumpy-rabbits-chew.md Outdated
@dummdidumm
dummdidumm merged commit d653640 into master Jul 8, 2026
3 checks passed
@dummdidumm
dummdidumm deleted the zero-config-error-types branch July 8, 2026 20:48
@github-actions github-actions Bot mentioned this pull request Jul 8, 2026
renovate Bot added a commit to gwennlbh/svelte-mathml that referenced this pull request Jul 25, 2026
##### [v4.7.3](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.7.3)

##### Patch Changes

- feat: zero-config `+error.svelte` props ([#3076](sveltejs/language-tools#3076))
##### [v4.7.2](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.7.2)

##### Patch Changes

- fix: resolve tsgo bin path with package.json ([#3074](sveltejs/language-tools#3074))

- fix: report tsconfig errors in --tsgo-experimental-api ([#3070](sveltejs/language-tools#3070))
##### [v4.7.1](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.7.1)

##### Patch Changes

- fix: correctly parse --tsgo-experimental-api flag ([#3067](sveltejs/language-tools#3067))
##### [v4.7.0](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.7.0)

##### Minor Changes

- feat: add `--config` option ([#3066](sveltejs/language-tools#3066))

- feat: svelte-check tsgo support with experimental api ([#3036](sveltejs/language-tools#3036))

##### Patch Changes

- fix: load esm version of Vite ([#3065](sveltejs/language-tools#3065))

- fix: stop excluding workspaces under dot-prefixed ancestors ([#3037](sveltejs/language-tools#3037))

- Updated dependencies \[[`7a3464b`](sveltejs/language-tools@7a3464b), [`a2561fc`](sveltejs/language-tools@a2561fc)]:
  - [@sveltejs/load-config](https://github.com/sveltejs/load-config)@0.2.0
##### [v4.6.0](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.6.0)

##### Minor Changes

- feat: support reading Svelte config from `vite.config.js/ts` ([#3031](sveltejs/language-tools#3031))

##### Patch Changes

- Updated dependencies \[[`151cf45`](sveltejs/language-tools@151cf45)]:
  - [@sveltejs/load-config](https://github.com/sveltejs/load-config)@0.1.1
##### [v4.5.0](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.5.0)

##### Minor Changes

- feat: support Svelte 5 declaration tags ([#3033](sveltejs/language-tools#3033))

##### Patch Changes

- fix: properly handle props with the name `slot` inside Svelte 5 snippets ([#3030](sveltejs/language-tools#3030))

- feat: add support for svelte config ts/mts files ([#3009](sveltejs/language-tools#3009))
##### [v4.4.8](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.4.8)

##### Patch Changes

- feat: typescript 6.0 support ([#2985](sveltejs/language-tools#2985))
##### [v4.4.7](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.4.7)

##### Patch Changes

- fix: flush stdout/stderr before exit ([#3014](sveltejs/language-tools#3014))

- fix: report diagnostics in tsconfig.json ([#3005](sveltejs/language-tools#3005))
##### [v4.4.6](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.4.6)

##### Patch Changes

- fix: prevent config loading message in svelte-check --incremental ([#2974](sveltejs/language-tools#2974))

- fix: resolve svelte files with NodeNext in --incremental/tsgo ([#2990](sveltejs/language-tools#2990))

- perf: various optimization with ast walk ([#2969](sveltejs/language-tools#2969))

- fix: prevent error with escape sequence in attribute ([#2968](sveltejs/language-tools#2968))

- fix: typescript 6.0 compatibility ([#2988](sveltejs/language-tools#2988))
##### [v4.4.5](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.4.5)

##### Patch Changes

- fix: use Promise<Response> for async kit handler return types ([#2966](sveltejs/language-tools#2966))
##### [v4.4.4](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.4.4)

##### Patch Changes

- fix: more robust detection of `lang="ts"` attribute ([#2957](sveltejs/language-tools#2957))

- fix: pass filename to `warningFilter` ([#2959](sveltejs/language-tools#2959))

- fix: resolve svelte files under path alias in `--incremental/tsgo` mode ([#2955](sveltejs/language-tools#2955))
##### [v4.4.3](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.4.3)

##### Patch Changes

- fix: respect `@ts-ignore` etc comments within tags ([#2950](sveltejs/language-tools#2950))
##### [v4.4.2](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.4.2)

##### Patch Changes

- fix: resolve shims correctly in `--incremental/tsgo` mode ([`cd1ff2f`](sveltejs/language-tools@cd1ff2f))

- fix: include `references` in generated `tsconfig.json` in `--incremental/tsgo` mode ([`1990f74`](sveltejs/language-tools@1990f74))
##### [v4.4.1](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.4.1)

##### Patch Changes

- fix: handle relative imports reaching outside working directory when using `--incremental/--tsgo` flags ([#2942](sveltejs/language-tools#2942))

- fix: support SvelteKit zero types in svelte-check --incremental ([#2939](sveltejs/language-tools#2939))
##### [v4.4.0](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.4.0)

##### Minor Changes

- feat: provide `--incremental` and `--tsgo` flags ([#2932](sveltejs/language-tools#2932))

##### Patch Changes

- fix: ignore Unix domain sockets in file watcher to prevent crashes ([#2931](sveltejs/language-tools#2931))

- fix: properly use machine output by default for Claude Code ([`e9f58d2`](sveltejs/language-tools@e9f58d2))
##### [v4.3.6](https://github.com/sveltejs/language-tools/releases/tag/svelte-check%404.3.6)

##### Patch Changes

- fix: don't hoist type/snippet referencing $store ([#2926](sveltejs/language-tools#2926))
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