Repository navigation
Move the client to SvelteKit 3 - #321
Merged
Merged
Conversation
Dependabot opened these as #316 and #317, and neither could ever go green: adapter-static 3 requires kit ^2, adapter-static 4 requires kit ^3, so each pull request held one half of a pair and `npm ci` failed on the peer conflict before a single test ran. The three red checks on both were the same install failing three times. They land together or not at all. Four breaking changes and one override had to be dealt with. `svelte.config.js` is no longer read. Its contents move into the `sveltekit()` plugin in vite.config.ts, and the `kit` nesting is gone with it - every option sat one level deeper before. The comments move with the options, including the account of #260, which is the reason the version name is the commit. The generated tsconfig is now a virtual module, `$app/tsconfig`, and no longer supplies include/exclude or carries `$app/types` into an overridden `types` array, so all three are stated in tsconfig.json. `$lib` is removed. SvelteKit offers `alias: { '$lib': 'src/lib' }` to keep it, but that option is itself deprecated and will be removed, so this moves to the `#lib` subpath imports it points at instead - 46 specifiers across 16 files. The specifiers carry file extensions because the tools disagree about inferring them. A fallback list of candidate extensions satisfies TypeScript, and Rolldown takes only the first entry and fails the build on the first `.svelte` import it meets. One exact path is read the same way by both; CONTRIBUTING.md records it, because `#lib/protection` looks right and resolves to nothing. The `cookie` override is removed. It existed because kit 2 asked for `^0.6.0`, below the version that fixed a name-parsing flaw. Kit 3 asks for `^2.0.1`, so the entry had nothing left to do - and it had turned harmful, pinning cookie back to a CommonJS 0.7.2 without the named exports kit 3 imports, which failed the build on `parseCookie`. `npm ls cookie` now resolves to 2.0.1 unaided and npm audit reports nothing. docs/workflows/dependabot.md set the condition for dropping it and that condition is the one that was met. One warning is accepted rather than silenced. SvelteKit wants the service worker out of this type-check program, and it is already excluded as an entry point - but its test imports it, and exclude only limits the root set, so it comes back. Silencing it means excluding the test too, and then nothing type-checks the file that answers download requests. #320 has the fix worth making, which needs its own tsconfig and a change to three gates. Verified: svelte-check 0 errors over 416 files, 572 unit tests, biome, vite build, npm ci, notices, toolchains, workflows, asset audit, go build, go vet, go test, golangci-lint. The built output matches a kit 2 baseline built from origin/main in a worktree - same files, same absolute /_app references, which the SPA fallback has always emitted. Playwright was not run locally; the browser download would not complete here, so CI is what confirms it. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Signed-off-by: Serraniel <mail@serraniel.dev>
…gether #316 and #317 were a kit 3 bump and an adapter-static 4 bump in separate pull requests. adapter-static 4 requires kit ^3 and adapter-static 3 requires kit ^2, so each one failed npm ci on the other's peer range and neither could ever pass. The three red checks on each were one install failing three times. The configuration already had this shape for vitest, added when the same thing happened to @vitest/coverage-v8 in #99, so this is that group's reasoning applied to the set that just demonstrated it needs it. vite is included because kit declares it as a peer with a major range, so a vite major alone fails identically. docs/workflows/dependabot.md gains the general case, which it was missing: it documented the dependencies deliberately kept out of groups and said nothing about the ones deliberately forced into them, so the only record was a comment in the configuration. It also records the symptom, because a wall of ERESOLVE is not a breaking change and reading the upstream changelog first wastes the afternoon. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Signed-off-by: Serraniel <mail@serraniel.dev>
This was referenced Oct 21, 2026
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Replaces #316 and #317, which could not pass individually and were not two
problems.
The red CI was one install, counted three times
@sveltejs/adapter-static3 requires@sveltejs/kit^2, and version 4requires
^3. Dependabot opened one pull request for each half:npm cisaid^2.0.0^3.0.0-next.0Both died in
npm cibefore a single test ran, which is why Unit tests,Cross-language crypto vectors and Playwright flows were all red on both:
three jobs reporting the same install. Neither pull request could ever have
gone green, and no amount of rebasing would have changed that.
Four breaking changes
svelte.config.jsis no longer read. Its contents move into thesveltekit()plugin invite.config.ts, and thekitnesting disappears withit — every option sat one level deeper before. The comments move with their
options, including the account of #260, which is why the version name is the
commit and not a timestamp.
The generated tsconfig is a virtual module now,
$app/tsconfig. It nolonger writes into
.svelte-kit, no longer suppliesinclude/exclude, andno longer survives an overridden
typesarray, so all three are stated intsconfig.json.$libis removed. SvelteKit offersalias: { '$lib': 'src/lib' }to keepit working, but that option is itself deprecated and slated for removal, so
taking it would only move this same work to the next major. This migrates to
the
#libsubpath imports it points at instead — 46 specifiers across 16files.
cookiehad to stop being overridden. The entry existed because kit 2asked for
^0.6.0, below the release that fixed a name-parsing flaw. Kit 3asks for
^2.0.1, so it had nothing left to do — and it had become activelyharmful, pinning
cookieback to a CommonJS 0.7.2 that lacks the named exportskit 3 imports. The build failed on
parseCookieuntil it was gone.npm ls cookienow resolves to 2.0.1 unaided andnpm auditreports nothing.docs/workflows/dependabot.mdset the condition for dropping it, and that isthe condition that was met.
The specifiers carry file extensions, because the tools disagree
"#lib/*": "./src/lib/*"is an exact mapping — Node subpath imports add noextensions. The obvious fix is a fallback list, and it does satisfy TypeScript:
svelte-checkwent to 0 errors on that, and then the build failed, becauseRolldown takes only the first entry and never reaches the second:
Two tools reading one declaration differently is not something to ship, so the
extension is written at each import site and the mapping stays single and
exact.
CONTRIBUTING.mdrecords it, because#lib/protectionlooks correctand resolves to nothing.
So it does not happen again
.github/dependabot.ymlgains asveltekitgroup covering the whole peer ringacross every update type, majors included. The configuration already had this
shape for
vitest, added when@vitest/coverage-v8did the same thing in #99;this is that reasoning applied to the set that just demonstrated it needs it.
viteis in the group because kit declares it as a peer with a major range, soa
vitemajor on its own fails identically.docs/workflows/dependabot.mdwas missing the general case entirely — itexplained which dependencies are kept out of groups and said nothing about
the ones forced into them. It now also records the symptom, since a wall of
ERESOLVEis not a breaking change and reading the upstream changelog firstcosts an afternoon.
One warning is accepted, not silenced
svelte-kit syncprintstsconfig_invalid, asking for the service worker toleave this type-check program. It is already excluded as an entry point — but
src/service-worker.test.tsimports it, andexcludeonly limits the rootset, so it comes back.
tsc --listFilesshows both files.Silencing it means excluding the test too, and then nothing type-checks the
file that answers download requests. That is the worse trade, so the warning
stays and
tsconfig.jsonsays why. #320 has the fix worth making — the workerneeds its own project with
lib: ["ESNext", "WebWorker"], which touchescheck,verify.shand the CI job, so it is not folded in here. Note thatSvelteKit 2 behaved the same way; the only new thing is that it now mentions
it.
Verified
svelte-check0 errors over 416 files · 572 unit tests · biome ·vite build·
npm ci· notices · toolchains · workflows · asset audit ·go build·go vet·go test·golangci-lint0 issues.Coverage floors for
internal/storeandinternal/blobfall short locallybecause
SENDAN_TEST_POSTGRESandSENDAN_TEST_S3are unset here; the scriptsays so itself, and neither package is touched.
I also built a kit 2 baseline from
origin/mainin a worktree to compareagainst, because the new
index.htmlreferences/_app/…absolutely and theconfig asks for
paths: { relative: true }. The baseline does exactly the same— 9 absolute references against 11 — so that is how the SPA fallback has always
been emitted and not something this introduced. Same top-level files, same 7
stylesheets.
on this machine, so CI is what confirms the three browser projects. Everything
else above ran here.
Closes #316
Closes #317
🤖 Generated with Claude Code