Conversation
🦋 Changeset detectedLatest commit: c47be02 The changes in this PR will be included in the next version bump. This PR includes changesets to release 6 packages
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 |
|
Finally it looks like we have a clean run and can go back to opening PRs against this branch. Will see how much work is involved in fixing the conflicts on #15574 |
|
Install the latest version of pnpm add https://pkg.svelte.dev/@sveltejs/kit/c/c47be02722ab385582145c6d29a40f3cbf15aaa7Open in |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Noticed `.as(type, value) renders correct values` failing in this run: https://github.com/sveltejs/kit/actions/runs/30681430489/job/91319090645. Both Playwright projects run the same test files against one shared server, so state that one test mutates is visible to tests in the other project, and retries rerun against the already-mutated state. This audits the test apps for that class. Mutable remote-function state in async and options-2 is now keyed per browser session the way `query-command.remote.js` already does it, the counter tests in basics reset first or assert relatively, and the double-mount test in writes only runs with JS since the file it rewrites on disk is shared with the no-js project. Verified with `--workers=1 --repeat-each=2` against one server: the four basics counter tests fail their second run on version-3 and pass here. --------- Co-authored-by: Rich Harris <rich.harris@vercel.com>
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to version-3, this PR will be updated.⚠️ ⚠️ ⚠️ ⚠️ ⚠️ ⚠️ `version-3` is currently in **pre mode** so this branch has prereleases rather than normal releases. If you want to exit prereleases, run `changeset pre exit` on `version-3`.⚠️ ⚠️ ⚠️ ⚠️ ⚠️ ⚠️ # Releases ## @sveltejs/kit@3.0.0-next.14 ### Major Changes - breaking: refresh all load functions/queries when clicking a link to the current URL ([#16572](#16572)) - breaking: only include routes with a `+page` or `+server` in `RouteId` ([#16580](#16580)) - breaking: require Node 22.17 ([#16597](#16597)) - breaking: `preloadCode` now takes a route ID (e.g. `/blog/[slug]`) instead of a pathname. Route IDs are not prefixed with `paths.base` ([#16576](#16576)) - breaking: remove deprecated `.run()` method from live queries ([#16573](#16573)) ### Minor Changes - feat: return the list of compressed files from `builder.compress` ([#16566](#16566)) - feat: add `page` and `endpoint` booleans to `$app/manifest`'s `routes`, and export a `ManifestRoute` type ([#16594](#16594)) - feat: add `PageRouteId` and `EndpointRouteId` to `$app/types` ([#16594](#16594)) ### Patch Changes - fix: generate valid `Path` types for routes with optional or rest params, several params in one segment, or escape sequences ([#16577](#16577)) - fix: decode all numeric character references, including above `ffff`, when crawling prerendered pages ([#16611](#16611)) - chore: deduplicate request hashing for serialized fetch responses ([#16499](#16499)) - fix: don't treat `Object.prototype` members as param matchers during validation ([#16612](#16612)) - fix: exclude routes without a page or endpoint from `routes` in `$app/manifest`, and remove directories with no route files from `LayoutParams` ([#16588](#16588)) - chore: reuse base64 and text decoding helpers ([#16608](#16608)) - fix: record the mime types of prerendered paths in the server manifest ([#16564](#16564)) - chore: only generate each route's resolution module once when prerendering ([#16576](#16576)) - fix: expand `[x+nn]` and `[u+nnnn]` escape sequences when resolving a route id to a pathname ([#16570](#16570)) - fix: allow routes to contain `[` and `]` via the `[x+5b]` and `[x+5d]` escapes ([#16569](#16569)) - chore: remove the dead `SSRState.fallback` field and name the server state fork semantics ([#16598](#16598)) - fix: import resolved peer dependencies as file URLs so project-relative resolution works on Windows ([#16618](#16618)) - fix: write generated tsconfig to `node_modules/$app/tsconfig.json` so that tools with simplified tsconfig resolution can find it ([#16589](#16589)) - fix: prerender and crawl pages whose `content-type` header carries a `charset` parameter ([#16567](#16567)) - fix: stream promised `read` results lazily instead of eagerly buffering them ([#16622](#16622)) - fix: correctly decode `[u+nnnn]` escape sequences above `ffff` ([#16611](#16611)) ## @sveltejs/adapter-auto@8.0.0-next.2 ### Patch Changes - fix: convert resolved adapter path to a file URL before importing, so builds work on Windows ([#16618](#16618)) - Updated dependencies [[`c3f58bb`](c3f58bb), [`b655dc7`](b655dc7), [`a70cc4f`](a70cc4f), [`b325afb`](b325afb), [`e76b3d7`](e76b3d7), [`58f47eb`](58f47eb), [`fe9d8d9`](fe9d8d9), [`0c7bbd7`](0c7bbd7), [`08d7e2a`](08d7e2a), [`f70f679`](f70f679), [`0624b26`](0624b26), [`0624b26`](0624b26), [`f4222ad`](f4222ad), [`089628b`](089628b), [`d8617b3`](d8617b3), [`c7369a1`](c7369a1), [`5e5e592`](5e5e592), [`60057c1`](60057c1), [`f70f679`](f70f679), [`38f1528`](38f1528), [`40092f3`](40092f3), [`ff4247e`](ff4247e), [`79a5de5`](79a5de5), [`a70cc4f`](a70cc4f)]: - @sveltejs/kit@3.0.0-next.14 ## @sveltejs/adapter-cloudflare@8.0.0-next.4 ### Patch Changes - fix: avoid caching immutable asset 404s ([#16627](#16627)) - Updated dependencies [[`c3f58bb`](c3f58bb), [`b655dc7`](b655dc7), [`a70cc4f`](a70cc4f), [`b325afb`](b325afb), [`e76b3d7`](e76b3d7), [`58f47eb`](58f47eb), [`fe9d8d9`](fe9d8d9), [`0c7bbd7`](0c7bbd7), [`08d7e2a`](08d7e2a), [`f70f679`](f70f679), [`0624b26`](0624b26), [`0624b26`](0624b26), [`f4222ad`](f4222ad), [`089628b`](089628b), [`d8617b3`](d8617b3), [`c7369a1`](c7369a1), [`5e5e592`](5e5e592), [`60057c1`](60057c1), [`f70f679`](f70f679), [`38f1528`](38f1528), [`40092f3`](40092f3), [`ff4247e`](ff4247e), [`79a5de5`](79a5de5), [`a70cc4f`](a70cc4f)]: - @sveltejs/kit@3.0.0-next.14 ## @sveltejs/adapter-node@6.0.0-next.7 ### Patch Changes - fix: serve static files with the Content-Type recorded in the manifest ([#16564](#16564)) - fix: don't send `Vary: Accept-Encoding` for assets that were never precompressed ([#16566](#16566)) - Updated dependencies [[`c3f58bb`](c3f58bb), [`b655dc7`](b655dc7), [`a70cc4f`](a70cc4f), [`b325afb`](b325afb), [`e76b3d7`](e76b3d7), [`58f47eb`](58f47eb), [`fe9d8d9`](fe9d8d9), [`0c7bbd7`](0c7bbd7), [`08d7e2a`](08d7e2a), [`f70f679`](f70f679), [`0624b26`](0624b26), [`0624b26`](0624b26), [`f4222ad`](f4222ad), [`089628b`](089628b), [`d8617b3`](d8617b3), [`c7369a1`](c7369a1), [`5e5e592`](5e5e592), [`60057c1`](60057c1), [`f70f679`](f70f679), [`38f1528`](38f1528), [`40092f3`](40092f3), [`ff4247e`](ff4247e), [`79a5de5`](79a5de5), [`a70cc4f`](a70cc4f)]: - @sveltejs/kit@3.0.0-next.14 ## @sveltejs/adapter-static@4.0.0-next.3 ### Patch Changes - fix: avoid caching immutable asset 404s when configuring for Vercel ([#16626](#16626)) - Updated dependencies [[`c3f58bb`](c3f58bb), [`b655dc7`](b655dc7), [`a70cc4f`](a70cc4f), [`b325afb`](b325afb), [`e76b3d7`](e76b3d7), [`58f47eb`](58f47eb), [`fe9d8d9`](fe9d8d9), [`0c7bbd7`](0c7bbd7), [`08d7e2a`](08d7e2a), [`f70f679`](f70f679), [`0624b26`](0624b26), [`0624b26`](0624b26), [`f4222ad`](f4222ad), [`089628b`](089628b), [`d8617b3`](d8617b3), [`c7369a1`](c7369a1), [`5e5e592`](5e5e592), [`60057c1`](60057c1), [`f70f679`](f70f679), [`38f1528`](38f1528), [`40092f3`](40092f3), [`ff4247e`](ff4247e), [`79a5de5`](79a5de5), [`a70cc4f`](a70cc4f)]: - @sveltejs/kit@3.0.0-next.14 ## @sveltejs/enhanced-img@1.0.0-next.3 ### Patch Changes - chore: bump `vite-imagetools` to v11 ([#16630](#16630)) ## @sveltejs/package@3.0.0-next.4 ### Patch Changes - chore: remove dependency on sade ([#16619](#16619)) - fix: import resolved peer dependencies as file URLs so project-relative resolution works on Windows ([#16618](#16618)) - fix: emit declarations when the tsconfig lives above the package root ([#16568](#16568)) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Follow-up to #15529 (comment). `author_association` includes read-only collaborators, so the gate now checks actual permissions. Checkout is pinned to the sha the comment was made on and the push fails if the branch moved. The fork-rejection comment always 403ed (no `pull-requests: write`), so the message moved to the job log.
closes #16628 --------- Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com> Co-authored-by: Vercel <vercel[bot]@users.noreply.github.com> Co-authored-by: Rich-Harris <hello@rich-harris.dev>
…6614) `getSetCookie` bypassed the `filterSerializedResponseHeaders` guard, so reads that work during SSR silently return `[]` after hydration. `has()` and iteration still bypass it; a Proxy would cover everything if that's the way to go. --- ### Please don't delete this checklist! Before submitting the PR, please make sure you do the following: - [x] It's really useful if your PR references an issue where it is discussed ahead of time. In many cases, features are absent for a reason. For large changes, please create an RFC: https://github.com/sveltejs/rfcs - [x] This message body should clearly illustrate what problems it solves. - [x] Ideally, include a test that fails without this PR but passes with it. ### Tests - [x] Run the tests with `pnpm test` and lint the project with `pnpm lint` and `pnpm check` ### Changesets - [x] If your PR makes a change that should be noted in one or more packages' changelogs, generate a changeset by running `pnpm changeset` and following the prompts. Changesets that add features should be `minor` and those that fix bugs should be `patch`. Please prefix changeset messages with `feat:`, `fix:`, or `chore:`. ### Edits - [x] Please ensure that 'Allow edits from maintainers' is checked. PRs without this option may be closed.
closes #16607 closes #16638 closes #15813 closes #4615 closes #9884 This PR removes the automatic caching that the Cloudflare adapter does (and in doing so removes the dependency on worktop). Users are better off using https://developers.cloudflare.com/workers/cache/ which requires an opt-in via the config file. --- ### Please don't delete this checklist! Before submitting the PR, please make sure you do the following: - [x] It's really useful if your PR references an issue where it is discussed ahead of time. In many cases, features are absent for a reason. For large changes, please create an RFC: https://github.com/sveltejs/rfcs - [x] This message body should clearly illustrate what problems it solves. - [ ] Ideally, include a test that fails without this PR but passes with it. ### Tests - [x] Run the tests with `pnpm test` and lint the project with `pnpm lint` and `pnpm check` ### Changesets - [x] If your PR makes a change that should be noted in one or more packages' changelogs, generate a changeset by running `pnpm changeset` and following the prompts. Changesets that add features should be `minor` and those that fix bugs should be `patch`. Please prefix changeset messages with `feat:`, `fix:`, or `chore:`. ### Edits - [x] Please ensure that 'Allow edits from maintainers' is checked. PRs without this option may be closed.
Same treatment #15272 gave sade, applied to chokidar: watch mode needs recursive file events with unlink detection, and `fs.watch(dir, { recursive: true })` provides them at the Node 22 floor. --------- Co-authored-by: Tee Ming <chewteeming01@gmail.com> Co-authored-by: Rich Harris <rich.harris@vercel.com>
Reverts #16621 — doing this rather than fixing it because it's not a Kit 3 priority. This broke stuff silently (because `watch` tests don't run in CI). The issue is that renames aren't properly accounted for — renaming a directory `foo` to `bar` (or `sub` to `sub2` in the test) means that pending `unlink` events are created for everything inside `foo`, with no corresponding events for the files that are now inside `bar`. As a result, files are removed from the output directory instead of being renamed (or recreated).
Fixes a pre-existing async live-query test flake observed on #16944 in CI run https://github.com/sveltejs/kit/actions/runs/32994679500. The stats button previously awaited `get_stats()` without first refreshing its cached query. Cache eviction therefore depended on `FinalizationRegistry`/GC timing, and CI polling could repeatedly read the original `cleanup_count` after reconnecting. Explicitly start a refresh, then await `get_stats()` again. Query proxies for the same query share the cached resource, so the second proxy resolves with fresh server state while using the idiomatic remote-query API. The follow-up passed async-app type checking, formatting, and diff validation. A targeted Playwright build also completed, though browser launch was unavailable in the sandbox because required Chromium system libraries could not be installed. --------- Co-authored-by: svelte-triage-bot <team@svelte.com>
…16903) Fixed #12556 --- ### Please don't delete this checklist! Before submitting the PR, please make sure you do the following: - [x] It's really useful if your PR references an issue where it is discussed ahead of time. In many cases, features are absent for a reason. For large changes, please create an RFC: https://github.com/sveltejs/rfcs - [x] This message body should clearly illustrate what problems it solves. - [x] Ideally, include a test that fails without this PR but passes with it. ### Tests - [x] Run the tests with `pnpm test` and lint the project with `pnpm lint` and `pnpm check` ### Changesets - [x] If your PR makes a change that should be noted in one or more packages' changelogs, generate a changeset by running `pnpm changeset` and following the prompts. Changesets that add features should be `minor` and those that fix bugs should be `patch`. Please prefix changeset messages with `feat:`, `fix:`, or `chore:`. ### Edits - [x] Please ensure that 'Allow edits from maintainers' is checked. PRs without this option may be closed. --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Co-authored-by: Nic Polumeyv <nicolas.polum@outlook.com> Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com> Co-authored-by: Nic Polumeyv <162764842+Nic-Polumeyv@users.noreply.github.com>
…6944) I was today years old when I discovered `<input type="image" />` and how it works and it got me unreasonably excited. So obviously, I had to try if it worked correctly with remote functions, and it turns out it doesn't. This PR fixes that. ## How it works in HTML Initially, I thought that `<input type="image" />` was just to show an image as a submit button, a relic of an era where you couldn't properly style buttons. But it turns out that it does something much more interesting. Because when you submit a form with `<input type="image" />` two properties are added to the `FormData` (or to the search): `name.x` and `name.y` with the coordinates of where the pointer was (inside the image) when it was clicked. I legit never used it, but I can see how this could sometimes be necessary, and it would be a shame to lose this progressive enhanced functionality. ## The fix The fix works both type wise and runtime wise by allowing the user to declare `as("image")` when the field is an object with `x` and `y` as numbers. A few important notes: - If it has any other property you can't specify `field.as("image")` as you would have no way to set the last property - You can still set `field.x.as("text")` and `field.y.as("text")` so if by chance you have an `{ x: number; y: number }` schema, but it's not for an `image` input you can still use them. Now the kind-of bad news: I think this is a breaking change in case someone was using `as("image")` on a field which was not `{ x: number; y: number }`...however this would've error at runtime before (because of the extra fields) so maybe is acceptable? P.s. I know AIs love to write in paragraphs, but this was handwritten lol --------- Co-authored-by: Nic Polumeyv <nicolas.polum@outlook.com> Co-authored-by: Nic Polumeyv <nicolas.polum@gmail.com> Co-authored-by: Rich Harris <rich.harris@vercel.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
…the server runtime (#16967) `Server` keeps the manifest in `#manifest` and passes it to `respond`, from where it travels through 16 parameter positions in `runtime/server`, down to `has_prerendered_path` and `load_error_components`. The same object is written to `runtime/server/internal.js` by `set_manifest` in the `Server` constructor, and `$app/server`'s `read`, `$app/paths`'s `resolve` and the `read_implementation` branch in `fetch.js` already read it from there, so `fetch.js` mixed the parameter and the module singleton in one function. The parameter is gone and every reader imports `manifest` from `internal.js`, the same shape #16871 gave `options`. The `Server` constructor argument and its `set_manifest` call stay. In dev that call runs per request, so a request in flight during a manifest regeneration now sees the regenerated manifest, which `read` and `resolve` already did. Closes #16519. --------- Co-authored-by: Tee Ming <chewteeming01@gmail.com>
…kers` (#16754) Breaking #16705 into smaller pieces; this is the first step of making the dev environment closer to the workerd runtime. Instead of accessing Cloudflare bindings on `platform.env`, you would do the following: ```js import { env } from 'cloudflare:workers'; export function GET({ request }) { const value = await env.KV.get('key'); // instead of platform.env const userCountry = request.cf.country; // instead of platform.cf const cache = caches.open('name'); // instead of platform.caches } ``` --- ### Please don't delete this checklist! Before submitting the PR, please make sure you do the following: - [ ] It's really useful if your PR references an issue where it is discussed ahead of time. In many cases, features are absent for a reason. For large changes, please create an RFC: https://github.com/sveltejs/rfcs - [x] This message body should clearly illustrate what problems it solves. - [x] Ideally, include a test that fails without this PR but passes with it. ### Tests - [x] Run the tests with `pnpm test` and lint the project with `pnpm lint` and `pnpm check` ### Changesets - [x] If your PR makes a change that should be noted in one or more packages' changelogs, generate a changeset by running `pnpm changeset` and following the prompts. Changesets that add features should be `minor` and those that fix bugs should be `patch`. Please prefix changeset messages with `feat:`, `fix:`, or `chore:`. --------- Co-authored-by: Tee Ming <chewteeming01@gmail.com>
…dows (#16972) `create_function_bundle` traces with `base` set to the filesystem root. nft treats any absolute-looking string with a dynamic segment as an asset glob, and the server output has URL strings like ```js `/${app_dir}/routes${route_id}` // runtime/pathname.js ``` On Linux this resolves to `/<*>/routes`, the parent directory is `''`, the stat fails and nothing happens. On Windows it resolves to `D:\<*>\routes`, the parent `D:` stats fine, and nft runs `glob('D:/**/*/routes')` over the whole drive, which never finishes once it hits `pagefile.sys`. nft also evaluates `process.cwd()` as `base` unless told otherwise, so `path.join(process.cwd(), 'asset.txt')` was traced from `/` and never bundled. nft calls `ignore` with the glob relative to `base` before walking, and a base-rooted glob is `**\*\routes`. The cwd case has a regression test; the root-glob case can't fire on Linux for the reason above. Fixes #16963. Supersedes #16964. Related: vercel/nft#609.
fixes the vite ecosystem ci error https://github.com/vitejs/vite-ecosystem-ci/actions/runs/32693769091/job/97332021820#step:7:1811 There is no point to us calling `resolve_peer(...)` for a Vite instance in the `vite/index.js` file anymore since we don't use to run the client build during a server build (SvelteKit 2 behaviour). Removing this should avoid the vite-ecosystem-ci error where the Vite runner `instanceof` check fails from two differently resolved Vite instances (the one that started the build and the one from our `resolve_peer`). --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
…-eval time (#16303) closes #14286 Dynamic `$app/env` values are normally populated when `Server.init()` calls `set_env()`. The problem is that `instrumentation.server.js` deliberately runs before `Server.init()`, so importing `$app/env` there gives you `undefined`. More subtly, instrumentation can share a chunk with application code and cause that code to evaluate early too, permanently capturing those undefined values at module scope. Basically, instrumentation should run before the application, but not before the minimum runtime state it is allowed to observe exists. This adds an environment initializer to `builder.instrument()`. Adapters provide the final env module location and generate the small platform-specific initializer; Kit handles the relative import, imports it before instrumentation, and only then dynamically imports the application entrypoint. The same ordering now applies in dev and preview. The official adapters initialize from their native runtime source: - Node, Vercel serverless and Netlify serverless use `process.env` - Cloudflare uses `env` from `cloudflare:workers` - Netlify edge uses `Deno.env.toObject()` Added tests for generated import paths, custom facades, module evaluation order, filename collisions, and a built adapter-node app reading dynamic env at instrumentation module scope. --------- Co-authored-by: Tee Ming <chewteeming01@gmail.com>
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: trueComment |
seeing if this fixes the CI failures on version-3 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Chores** - Updated project maintenance tooling to a newer patch version. - No user-facing changes are included in this release. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
For adapter-cloudflare, we need to add `@cloudflare/vite-plugin` to the
`vite.plugins` array. However, while configuring the plugin, we need
access to `svelte_config.out_dir` in order to tell it how to generate
the `wrangler` config.
This plugin allows adapters to do
```js
vite: ({ config }) => ({
plugins: [
some_plugin_that_requires(config),
]
}
```
Drive-by, also allows adapters to just specify a `plugins` array if they
don't need to specify `pre` and `post`. This is backwards-compatible.
---
### Please don't delete this checklist! Before submitting the PR, please
make sure you do the following:
- [ ] It's really useful if your PR references an issue where it is
discussed ahead of time. In many cases, features are absent for a
reason. For large changes, please create an RFC:
https://github.com/sveltejs/rfcs
- [x] This message body should clearly illustrate what problems it
solves.
- [ ] Ideally, include a test that fails without this PR but passes with
it.
### Tests
- [ ] Run the tests with `pnpm test` and lint the project with `pnpm
lint` and `pnpm check`
### Changesets
- [x] If your PR makes a change that should be noted in one or more
packages' changelogs, generate a changeset by running `pnpm changeset`
and following the prompts. Changesets that add features should be
`minor` and those that fix bugs should be `patch`. Please prefix
changeset messages with `feat:`, `fix:`, or `chore:`.
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
* **New Features**
* Adapters can now configure Vite plugins dynamically using the
validated SvelteKit configuration.
* Added support for defining adapter Vite plugins as an ordered list or
separate pre/post groups.
* Expanded public adapter configuration types and documentation.
* **Bug Fixes**
* Improved handling and ordering of adapter-provided Vite plugins.
* **Documentation**
* Documented adapter Vite configuration options and plugin ordering.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: Tee Ming <chewteeming01@gmail.com>
This should fix those pesky command flag errors pnpm/pnpm#14283
…16999) `svelte/server` exports `SyncRenderOutput` since 5.57.0, so `render_response` uses it instead of deriving the type from `render`. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Chores** * Updated the Svelte dependency to version 5.57.0. * Improved internal server rendering type handling. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
The url a `load` `fetch` response is serialized under is spelled out in `load_data.js`, `client.js` and `fetcher.js`, with comments asking each other to stay in sync. #14781 was those copies drifting. `fetch_cache_url` in `runtime/shared.js` is now the one definition. Supersedes #16792 without its hash changes. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Improved request URL handling for same-origin and cross-origin fetches. * Standardized URL normalization across client-side and server-side data fetching. * Preserved absolute URLs for cross-origin requests while using relative paths for same-origin requests. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
`walk` and `copy` in `packages/kit/src/utils/filesystem.js` stat every entry to find out whether it is a directory, and `copy` also calls `mkdirSync` for every file and rebuilds each returned path from the absolute target. `readdirSync` already knows the entry type, so both now read it from there, and `copy` creates each directory once and carries the relative path down the recursion. 5000 files in 200 directories: `walk` 24 ms to 4 ms, `copy` 114 ms to 86 ms. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Improved directory walking and copying for faster, more reliable file operations. * Directory symlinks are now handled correctly during traversal and copying. * Reduced unnecessary file metadata checks when processing directories. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
`builder.mimeTypes` stats every server asset for a size it never returns, and `create_assets` stats every file in `static/` for a `size` field nothing reads. Both calls are removed. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Performance** * Reduced unnecessary filesystem checks when processing static and server assets, improving build efficiency. * **Bug Fixes** * Simplified asset metadata by removing file-size information that was not needed. * Asset records now retain relevant file paths and MIME types without exposing size values. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
An attempt at providing CodeRabbit more context through the linked repositories setting and providing some initial automated workflows such as PR and issue labeling.
This one adds more automated package labeling for issues and `needs-platform-tests` for PRs which touch adapter code with platform tests
I named it wrongly so it wasn't picked up
This prevent CoreRabbit from approving a PR, which disables the merge protection before a human reviewer gets to it
removes settings that are already the default org-wide in the web UI <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Chores** - Streamlined project review and automation settings. - Added validation for pull request title prefixes before merging. - Refined file filtering and updated linked-repository guidance. - Retained documentation review instructions and automatic incremental reviews. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
I thought inheritance was the default but apparently it needs to be specified https://docs.coderabbit.ai/configuration/configuration-inheritance#enabling-inheritance
closes #9825 This maps `[[optional]]` segments to URLPattern's native optional named-parameter syntax (`:param?`). --- ### Please don't delete this checklist! Before submitting the PR, please make sure you do the following: - [x] It's really useful if your PR references an issue where it is discussed ahead of time. In many cases, features are absent for a reason. For large changes, please create an RFC: https://github.com/sveltejs/rfcs - [x] This message body should clearly illustrate what problems it solves. - [x] Ideally, include a test that fails without this PR but passes with it. ### Tests - [x] Run the tests with `pnpm test` and lint the project with `pnpm lint` and `pnpm check` ### Changesets - [x] If your PR makes a change that should be noted in one or more packages' changelogs, generate a changeset by running `pnpm changeset` and following the prompts. Changesets that add features should be `minor` and those that fix bugs should be `patch`. Please prefix changeset messages with `feat:`, `fix:`, or `chore:`. ### Edits - [x] Please ensure that 'Allow edits from maintainers' is checked. PRs without this option may be closed. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Fixed Netlify split-function routing for requests where optional URL parameters are omitted. * Improved generated function names and route matching for optional and rest parameters. * **Tests** * Added coverage for routes with optional parameters both present and absent. * Verified that generated functions include all expected route paths. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
closes #12523 Add deployed platform coverage proving redirects defined in a user `vercel.json` remain active with adapter-vercel's Build Output API deployment. --- ### Please don't delete this checklist! Before submitting the PR, please make sure you do the following: - [x] It's really useful if your PR references an issue where it is discussed ahead of time. In many cases, features are absent for a reason. For large changes, please create an RFC: https://github.com/sveltejs/rfcs - [x] This message body should clearly illustrate what problems it solves. - [x] Ideally, include a test that fails without this PR but passes with it. ### Tests - [ ] Run the tests with `pnpm test` and lint the project with `pnpm lint` and `pnpm check` Targeted: `pnpm -F test-vercel-basic test:build` (12 passed); oxfmt check passed. ### Changesets - [ ] If your PR makes a change that should be noted in one or more packages' changelogs, generate a changeset by running `pnpm changeset` and following the prompts. Changesets that add features should be `minor` and those that fix bugs should be `patch`. Please prefix changeset messages with `feat:`, `fix:`, or `chore:`. ### Edits - [x] Please ensure that 'Allow edits from maintainers' is checked. PRs without this option may be closed. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
closes #12023 Adds a deployed Vercel platform test to determine whether route-level `maxDuration` overrides work. The fixture exports `maxDuration: 1` from a route that runs for 3 seconds, then asserts Vercel returns `504` with `FUNCTION_INVOCATION_TIMEOUT`.
closes #13659 - Clarifies how Vercel ISR bypass tokens work: the token is captured at build time, so setting or changing it requires a new deployment. - removes inaccurate URL/header guidance - links Vercel's SvelteKit Draft Mode documentation. --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Co-authored-by: Simon H <5968653+dummdidumm@users.noreply.github.com> Co-authored-by: Elliott Johnson <hello@ell.iott.dev>
Fixes #17013. When `src/env` imports a dependency that imports `$app/env/private` or `$app/env/public`, loading the environment configuration depends on modules that have not yet been generated. Recognize this resolution failure and report the circular dependency directly instead of exposing the internal generated-module path. When available, the diagnostic now identifies the project-relative module that imported `$app/env/private` or `$app/env/public`. A regression test covers the transitive helper-import pattern and verifies that the responsible helper module is reported. ## Testing - `pnpm vitest run -c vitest.kit.config.js src/core/sync/sync.spec.js --reporter=verbose` - `pnpm -F @sveltejs/kit test:unit` - `pnpm format` - `pnpm -F @sveltejs/kit lint` - `pnpm -F @sveltejs/kit prepublishOnly` --------- Co-authored-by: svelte-triage-bot <team@svelte.com>
`packages/package/src/config.js` has its own `resolveConfig` + find-plugin loader, with `import_peer` and `resolve_peer` copied alongside it. It resolves under `'build'`, so reading the config runs the full `sync.all` and needs `src/app.html`, and it makes `vite` mandatory even for a library that only has a `svelte.config.js`. Use `@sveltejs/load-config` instead. It resolves under `'serve'` and falls back to `svelte.config.js` when the Vite config has no Svelte plugin.
Opened just so that I could easily see CI checks
You can try SvelteKit 3 by installing any of the packages following #15497 (comment) or the ones published with the
nexttag https://npmx.dev/package/@sveltejs/kitPlease don't delete this checklist! Before submitting the PR, please make sure you do the following:
Tests
pnpm testand lint the project withpnpm lintandpnpm checkChangesets
pnpm changesetand following the prompts. Changesets that add features should beminorand those that fix bugs should bepatch. Please prefix changeset messages withfeat:,fix:, orchore:.Edits