Skip to content

chore: standardize Vite plugin, build, prerender and adapter diagnostics - #17253

Open
elliott-with-the-longest-name-on-github wants to merge 1 commit into
message-box/routing-paramsfrom
message-box/build-prerender
Open

elliott-with-the-longest-name-on-github wants to merge 1 commit into
message-box/routing-paramsfrom
message-box/build-prerender

Conversation

@elliott-with-the-longest-name-on-github

Copy link
Copy Markdown
Contributor

Adds the Vite plugin, build, prerender, and adapter diagnostics to the @sveltejs/message-box-generated catalog.

There are a very few instances where we actually need the string from the error (either to pass it to a configured function or to accumulate it or whatever). There's probably a great solution to doing this at scale (for example, a template that returns a message instead of throwing), but the need for it is so small that I just added a capture_message helper function. It's kinda nasty but it's so niche I don't think it matters.

Probably most impactfully, I stopped using log.warn inside of SvelteKit, instead delegating all warnings to console.warn via our generated helpers, which is still formatted the same as it was before. I also rerouted log.warn to console.warn, which AFAICT was the intent all along. There should be no real end-user-visible-change here.


Stack created with GitHub Stacks CLI • Give Feedback 💬

@elliott-with-the-longest-name-on-github
elliott-with-the-longest-name-on-github added this pull request to stack #17254 September 28, 2026 22:17
@pkg-svelte-dev

Copy link
Copy Markdown

Install the latest version of @sveltejs/kit from e7fdd2a:

pnpm add https://pkg.svelte.dev/@sveltejs/kit/c/e7fdd2ace3e4eaaf015df1c394e55886a034bb20

Open in pkg.svelte.dev: https://pkg.svelte.dev/repos/kit/pr/17253

@changeset-bot

changeset-bot Bot commented Sep 28, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: e7fdd2a

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

This PR includes changesets to release 1 package
Name Type
@sveltejs/kit 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

node.start,
node.end,
`const ${fn} = prerender('unchecked', () => { throw new Error('Unexpectedly called prerender function. Did you forget to set { dynamic: true } ?') });`
`const ${fn} = prerender('unchecked', () => { throw new Error(${not_dynamic_message}) });`
@svelte-docs-bot

Copy link
Copy Markdown

This branch has not been deployed

No deployments
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