d3300c6a67908590266c363dba7b0835d9a194cf
)allow HandleServerError
hook to access getRequestEvent
(#13666)
fix: prevent Rollup warnings for undefined hooks (#13687)
afterNavigate
once on app start when SSR is disabled (#13593)getRequestEvent
to $app/server
(#13582)fetch
to reroute
(#13549)fix: correct navigation history with hash router and ensure load functions are rerun on user changes to URL hash (#13492)
fix: include universal load assets as server assets (#13531)
fix: Include root layout and error nodes even when apps have only prerendered pages (#13522)
fix: correctly preload data on mousedown
/touchstart
if code was preloaded on hover (#13530)
fix: avoid simulated CORS errors with non-HTTP URLs (#13493)
fix: correctly preload links on mousedown
/touchstart
(#13486)
fix: load CSS when using server-side route resolution (#13498)
fix: correctly find shared entry-point CSS files during inlining (#13431)
fix: add promise return type to the enhance
action callback (#13420)
fix: change server-side route resolution endpoint (#13461)
paths.relative
option is false
(#13412)feat: validate values for cache-control
and content-type
headers in dev mode (#13114)
feat: support server-side route resolution (#13379)
chore: don't error during development when using use:enhance
with +server
as some third party libraries make it possible to POST forms to it (#13397)
fix: skip hooks for server fetch to prerendered routes (#13377)
fix: ignore non-entry-point CSS files during inlining (#13395)
fix: default server fetch to use prerendered paths (#13377)
fix: avoid overwriting headers for sub-requests made while loading the error page (#13341)
fix: correctly resolve index file entrypoints such as src/service-worker/index.js
(#13354)
fix: correctly handle relative anchors when using the hash router (#13356)
feat: add ability to invalidate a custom identifier on goto()
(#13256)
feat: remove the postinstall
script to support pnpm 10 (#13304)
NOTE: users should add "prepare": "svelte-kit sync
" to their package.json
in order to avoid the following warning upon first running Vite:
▲ [WARNING] Cannot find base config file "./.svelte-kit/tsconfig.json" [tsconfig.json]
tsconfig.json:2:12:
2 │ "extends": "./.svelte-kit/tsconfig.json",
╵ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
feat: provide PageProps
and LayoutProps
types (#13308)
perf: shorten chunk file names (#13003)
fix: strip internal data before passing URL to reroute
(#13092)
fix: support absolute URLs and reroutes with data-sveltekit-preload-code="viewport"
(#12217)
fix: use current window.fetch
for server load fetch requests (#13315)
fix: resolve symlinks when handling routes (#12740)
fix: prevent infinite reload when using the hash router and previewing /index.html
(#13296)
fix: service worker base path in dev mode (#12577)
chore: error during development when using use:enhance
with +server
(#13197)
chore: add most common status codes to redirect()
JS documentation (#13301)
fix: correctly link to assets inlined by the inlineStyleThreshold
option (#13068)
fix: fall back to importing dynamic dependencies relative to SvelteKit package (#12532)
fix: use arrow function types over bound funcs (#12955)
fix: correctly navigate when hash router is enabled and the browser encodes extra hashes (#13321)
fix: fix race-condition when not using SSR when pressing back before initial load (#12925)
fix: remove ":$" from virtual module ids to allow dev server to work with proxies (#12157)
fix: upgrade esm-env to remove warning when NODE_ENV is not set (#13291)
fix: handle Redirect
thrown from root layout load function when client-side navigating to a non-existent page (#12005)
fix: make param matchers generated type import end with .js
(#13286)
fix: correctly notify page store subscribers (#13205)
fix: prerender data when there is no server load but the trailingSlash
option is set from the server (#13262)
fix: correctly remove navigation callbacks when returning function in onNavigate (#13241)
fix: add CSP hashes/nonces to inline styles when using bundleStrategy: 'inline'
(#13232)
fix: silence dev/prod warning during sync (#13244)
bundleStrategy: 'inline'
option (#13193)goto(...)
, to handle case where URL is mutated (#13196)bundleStrategy: 'split' | 'single'
option (#13173)fix: correctly resolve no hooks file when a similarly named directory exists (#13188)
fix: correctly resolve $app/state
on the server with Vite 5 (#13192)
navigating.current.<x>
with navigating.<x>
(#13174)$app/state
module (#13140)build.minify
setting when building the service worker (#13143)init
hook from get_hooks
(#13136)init
hook (#13103)hooks.js
from overwriting hooks from hooks.server.js
(#13104)fix: ensure error messages are escaped (#13050)
fix: escape values included in dev 404 page (#13039)
fix: prevent duplicate fetch request when using Request with load function's fetch (#13023)
fix: do not override default cookie decoder to allow users to override the cookie
library version (#13037)
fix: only add nonce to script-src-elem
, style-src-attr
and style-src-elem
CSP directives when unsafe-inline
is not present (#11613)
fix: support HTTP/2 in dev and production. Revert the changes from #12907 to downgrade HTTP/2 to TLS as now being unnecessary (#12989)
ActionFailure
objects (#12878)fix: warn on invalid cookie name characters (#12806)
fix: when using @vitejs/plugin-basic-ssl
, set a no-op proxy config to downgrade from HTTP/2 to TLS since undici
does not yet enable HTTP/2 by default (#12907)
fix: ensure element is focused after subsequent clicks of the same hash link (#12866)
fix: avoid preload if event default was prevented for touchstart
and mousedown
events (#12887)
fix: avoid reloading behaviour for hash links with data-sveltekit-reload if the hash is on the same page (#12866)
fix: include importer in illegal import error message (#12820)
fix: don't try reading assets directly that aren't present (#12876)
fix: decode non-latin characters when previewing prerendered pages (#12874)
fix: better error message when a Result
is returned from a form action (#12829)
docs: update URLs for new svelte.dev site (#12857)
chore: upgrade to sirv 3.0 (#12796)
fix: warn when form action responses are lost because SSR is off (#12063)
fix: correctly handle relative paths when fetching assets on the server (#12113)
fix: decode non ASCII anchor hashes when scrolling into view (#12699)
fix: page response missing CSP and Link headers when return promise in load
(#12418)
fix: only preload links that have a different URL than the current page (#12773)
fix: revert change to replace version in generateBundle (#12779)
fix: catch stack trace fixing errors thrown in web containers (#12775)
fix: use absolute links in JSDoc comments (#12772)
fix: ensure a changing version
doesn't affect the hashes for chunks without any actual code changes (#12700)
fix: prevent crash when logging URL search params in a server load function (#12763)
chore: revert update dependency cookie to ^0.7.0 (#12767)
load
functions (#12716)<form target="_blank">
and ` submissions (#11936)node:process
instead of using globals (#12641)fix: asynchronously instantiate components when using Svelte 5 (#12613)
fix: use {@render ...}
tag when generating default fallback page for svelte 5 apps (#12653)
fix: emulate event.platform
even when the route does not exist (#12513)
6056ba30e29ac5747c356fbf1a42dd71f2c4aa1f
)root.svelte
instead of svelte:component
for svelte 5 (#12584)binding_non_reactive
warning in generated root component (you also need to update to svelte@5.0.0-next.204
) (#12524)fix: respect HTML attributes enctype
and formenctype
for forms with use:enhance
(#12198)
fix: prevent client import error when a hooks.server
file imports a private environment variable (#12195)
fix: set default Content-Type
header to application/x-www-form-urlencoded
for POST
form submissions with use:enhance
to align with native form behaviour (#12198)
fix: hrefs that start with config.prerender.origin
are now crawled (#12277)
chore: add keywords for discovery in npm search (#12330)
fix: handle whitespace in HTTP Accept header (#12292)
fix: exclude server files from optimizeDeps.entries (#12242)
fix: bump import-meta-resolve to remove deprecation warnings (#12240)
fix: yield main thread before navigating (#12225)
fix: correctly handle aliases to files in the .svelte-kit
directory (#12220)
fetch
(#11904)data-sveltekit-preload-data
fails to fetch due to network error (#11944)fix: revert tsconfig change that includes svelte.config.js (#11908)
fix: exclude server worker from tsconfig again (#11727)
fix: prevent stale values after invalidation (#11870)
fix: prevent false positive history.pushState
and history.replaceState
warnings (#11858)
fix: relax status code types (#11781)
fix: popstate
navigations take pushState
navigations into account (#11765)
/@fs
prefix correctly on Windows when invoking read()
in dev mode (#11728)fix: use Vite's default value for build.target
and respect override supplied by user (#11688)
fix: properly decode base64 strings inside read
(#11682)
fix: default route config to {}
for feature checking (#11685)
fix: handle onNavigate
callbacks correctly (#11678)
$app/server
module with read
function for reading assets from filesystem (#11649)history
methods so other libs can monkeypatch it (#11657)__sveltekit/
module declarations from types (#11620)fix: return plaintext 404 for anything under appDir (#11597)
fix: populate dynamic public env without using top-level await, which fails in Safari (#11601)
fix: amend onNavigate type (#11599)
fix: better error message when peer dependency cannot be found (#11598)
reroute
hook (#11537)style-src
CSP directive when unsafe-inline
is not present (#11575)feat: add CSP support for style-src-elem (#11562)
fix: address CSP conflicts with sha/nonce during dev (#11562)
$env/static/public
in service workers (#10994)document.URL
contains credentials (#11179)fix: respect the trailing slash option when navigating from the basepath root page (#11388)
chore: shrink error messages shipped to client (#11551)
fix: always scroll to top when clicking a # or #top link (099608c428a49504785eab3afe3b2e76a9317bdf
)
fix: add nonce or hash to "script-src-elem", "style-src-attr" and "style-src-elem" if defined in CSP config (#11485)
fix: decode server data with stream: true
during client-side navigation (#11409)
fix: capture scroll position when using pushState
(#11540)
chore: use peer dependencies when linked (#11433)
fix: render SPA shell when SSR is turned off and there is no server data (#11405)
fix: upgrade sirv
and mrmime
to modernize javascript mime type (#11419)
chore: update primary branch from master to main (47779436c5f6c4d50011d0ef8b2709a07c0fec5d
)
fix: adjust missing inner content warning (#11394)
fix: prevent esbuild adding phantom exports to service worker (#11400)
fix: goto type include state (#11398)
fix: ensure assets are served gzip in preview (#11377)
breaking: remove top-level promise awaiting (#11176)
breaking: prevent use of dynamic env vars during prerendering, serve env vars dynamically (#11277)
breaking: remove deprecated use:enhance
callback values (#11282)
breaking: turn error
and redirect
into commands (#11165)
breaking: the type for depends
now requires a :
as part of the string (#11201)
breaking: remove baseUrl fallback from generated tsconfig (#11294)
breaking: fail if route with +page and +server is marked prerenderable (#11256)
breaking: remove resolvePath
in favour of resolveRoute
from $app/paths
(#11265)
breaking: drop support for Svelte 3 (#11168)
breaking: require Vite 5.0.3+ (#11122)
breaking: generate __data.json
files as sibling to .html
files (#11269)
breaking: fail if +page and +server have mismatched config (#11256)
breaking: error if form without multipart/form-data enctype contains a file input (#11282)
breaking: require paths pass to preloadCode to be prefixed with basepath (#11259)
breaking: @sveltejs/vite-plugin-svelte
is now a peer dependency and will need to be installed in each project using SvelteKit (#11184)
breaking: stop re-exporting vitePreprocess (#11297)
breaking: require path option when setting/deleting/serializing cookies (#11240)
breaking: tighten up error handling (#11289)
breaking: remove state option from goto in favor of shallow routing (#11307)
breaking: disallow external navigation with goto
(#11207)
breaking: upgrade to TypeScript 5. Default moduleResolution
to bundler
in user projects to be permissive in consuming and NodeNext
when running package
to be strict in distributing (#11160)
breaking: undefined is no longer a valid value for paths.relative (#11185)
breaking: require Node 18.13 or newer (#11172)
breaking: fix path resolution (#11276)
breaking: remove dangerZone.trackServerFetches
(#11235)
feat: add untrack to load (#11311)
feat: implement shallow routing (#11307)
feat: provide SvelteKit html typings (#11222)
feat: redact internal stack trace when reporting config errors (#11292)
feat: allow for fine grained invalidation of search params (#11258)
fix: prerender optional parameters as empty when entries
contains '*'
(#11178)
fix: resolve route config correctly (#11256)
fix: import Svelte types from svelte/compiler (#11188)
fix: reset invalid resources after a successful invalidation (#11268)
fix: Adjust fail method and ActionFailure type (#11260)
chore(deps): upgrade cookies dependency (#11189)
fix: prerendered root page with paths.base
config uses correct trailing slash option (#10763)
fix: correctly return 404 when a form action is not found (#11278)
response.arrayBuffer()
during ssr (#10535)fix: allow "false"
value for preload link options (#10555)
fix: call worker unref
instead of terminate
(#10120)
fix: correctly analyse exported server API methods during build (#11019)
fix: avoid error when back navigating before page is initialized (#10636)
fix: allow service-worker.js to import assets (#9285)
fix: distinguish better between not-found and internal-error (#11131)
fix: correctly return 415 when unexpected content types are submitted to actions (#11255)
chore: deprecate preloadCode
calls with multiple arguments (#11266)
resolveRoute
to $app/paths
, deprecate resolvePath
(#11261)fix: resolve relative cookie paths before storing (#11253)
chore: deprecate cookies.set/delete without path option (#11237)
fix: make sure promises from fetch handle errors (#11228)
fix: set runes option in generated root (#11111)
fix: retain URL query string for trailing slash redirects to prerendered pages (#11142)
fix: use runes in generated root when detecting Svelte 5 (#11028)
fix: correctly prerender pages that use browser globals and have SSR turned off (#11032)
fix: correctly show 404 for prerendered dynamic routes when navigating client-side without a root layout server load (#11025)
fix: add vite.config.js to included files in generated tsconfig (#10788)
fix: cache location.origin on startup (#11004)
fix: generate __data.json
for prerendered pages when SSR is turned off (#10988)
chore: add experimental compatibility for Svelte 5 (#11002)
File
Node polyfill for Node version 18.11.0+ (#10948)invalidateAll
boolean option to enhance
callback (#9889)fix: basic mime type handling for prerendered pages in preview (#10851)
chore: use just a single library (mrmime) for mime type handling (#10851)
chore: bump undici to address security issue (#10885)
fix: follow whatwg fetch spec for handling redirect loops (#10857)
fix: use window.fetch
in load
functions to allow libraries to patch it (#10009)
chore(deps): update dependency undici to ~5.26.0 (#10860)
fix: correctly update $page.url.hash
when navigating history (#10843)
fix: strip virtual module prefix from error messages (#10776)
fix: cancel ongoing navigation when the browser back button is hit to prevent an incorrect page from being rendered (#10727)
fix: only remove Vite manifest when copying files (#10782)
fix: correct line numbers in stack trace (#10769)
fix: correctly return 404 when navigating to a missing page and the root layout fetches a prerendered endpoint (#10565)
fix: allow optional param in middle of route (#10736)
chore: update undici
(#10641)
fallback
(#9755)fetch
for any scheme (#10699)event.route
(#10576)pkg.workspaces
(#10625)fix: adjust the type of Navigation["type"]
(#10599)
fix: allow logging $page.url
during prerendering (#10567)
fix: correctly restore trailing slash in url pathname for data requests (#10475)
fix: load trailing slash option from server even when there's no load function (#10475)
fix: make server assets available during vite preview
(#10511)
chore: upgrade undici
to 5.23.0 (#10240)
fix: prevent duplicate module preload (#10442)
docs: Elaborate on credentialed fetch
behaviour (#10421)
Response
s with immutable Headers
(#10367)fix: wait a tick before announcing new page title (#10363)
feat: more helpful error for preview if build output doesn't exist (#10337)
feat: add HEAD
server method (#9753)
feat: support caching of responses with Vary
header (except for Vary: *
) (#9993)
fix: avoid running load function on invalid requests (#9752)
fix: update page store when URL hash is changed from the address bar (#10202)
fix: include Vary: Accept
header to fix browser caching of adjacent pages and endpoints (#9993)
feat: add event.isSubRequest
boolean indicating whether this is a call to one of the app's own APIs during SSR (or prerendering) (#10170)
feat: add privatePrefix
to config.kit.env
(#9996)
feat: export VERSION
from @sveltejs/kit
(#9969)
docs: update inline NavigationType documentation (#10269)
perf: cache dynamic imports of nodes (#10080)
fix: batch synchronous invalidate invocations (#10145)
fix: allow rest params to be empty in resolvePath (#10146)
fix: correctly close dialogs when form is enhanced (#10093)
fix: precompress filter (#10185)
chore: remove tiny-glob
as a dependency (#10166)
fix: don't import types from svelte/internal
(#10172)
fix: don't skip rest parameter's matcher when there is a non-matching optional parameter (#10020)
fix: ensure fetch
respects headers from provided Request
(#10136)
fix: ensure optional routes with matchers and catch-all match correctly (#9987)
fix: disallow actions
export from a +layout.server
file (#10046)
fix: remove scrollbars from default error page (#10059)
feat: allow link options to be set to "true"
and "false"
(#10039)
feat: add resolvePath
export for building relative paths from route IDs and parameters (#9949)
fix: prevent history change when clicking same hash link (#10032)
fix: gracefully handle server endpoints that return Response
s with immutable Headers
when prerendering (#10030)
fix: do not add content-security-policy meta element if content is empty (#10026)
docs: correct ResolveOptions['preload']
inline documentation (#10037)
fix: avoid creating update check timer on the server (#10015)
load
s (#9945)fix: ensure styles are loaded in dev mode for routes containing special characters (#9894)
feat: warn users when enhancing forms with files but no enctype="multipart/form-data"
(#9888)
feat: unshadow data
and form
in enhance
and warn about future deprecation when used in dev
mode (#9902)
feat: crawl URLs in <meta>
tags (#9900)
fix: avoid trying to inline raw or url css imports (#9925)
feat: prerender in worker rather than subprocess to support Deno (#9919)
perf: add <script>
to prerendered redirects for faster redirects (#9911)
fix: add typing for vitePlugin
to Config
(#9946)
fix: stop setting Kit cookie defaults on cookies parsed from headers (#9908)
fix: only skip hydration with vite overlay if current page is an error (#9892)
fix: entry generation with mixed segments (#9879)
fix: use focusVisible: false
to prevent unwanted focus ring on navigation (#9861)
fix: realign state.branch on the client on first load (#9754)
fix: update $page.data
correctly after invalidate (#9798)
fix: file not found in manifest (#9846)
export const entries
(#9571)chore: more compact representation for invalidated search param (#9708)
chore: fix import path to app script on windows (#9743)
fix: make $app/navigation more resilient to bundler reordering (#9808)
fix: page load fetch()
now accepts the same input types for the body as the native fetch function (#9801)
fix: handle preload and filterSerializedResponseHeaders in sequence function (#9741)
fix: correctly replace state when data-sveltekit-replacestate
is used with a hash link (#9751)
fix: compute trailing slash on page server / data request (#9738)
fix: update vite-plugin-svelte to fix windows resolution issue (#9769)
chore: revert undici pin and upgrade version (#9740)
chore: upgrade vite-plugin-svelte for resolve improvements and warnings (#9742)
fix: provide better error when prerendered routes conflict with each other (#9692)
fix: prevent false positive warnings for fetch in Firefox and Safari (#9680)
fix: allow embedding two pages generated into the same page in "embedded" mode (#9610)
fix: don't include prerendered routes in default generateManifest (#9471)
fix: better error messages for handleable prerender failures (#9621)
fix: use correct relative paths when rendering base path (#9343)
fix: handle redirect thrown in handle hook in response to form action (#9658)
fix: do not call beforeNavigate for download links (#9660)
fix: correct allow header methods list for 405s (#9655)
fix: prevent routes/layouts from having conflicting files through resets or different extensions (#9590)
fix: prevent unhandled exceptions for invalid header values (#9638)
fix: gracefully handle failure to load hooks.server.js (#9641)
feat: set sourcemapIgnoreList to filter out non-source directories (#9619)
ba436c66
)fix: pin undici to 5.20.0 (#9591)
fix: address security advisory CVE-2023-29003 by including text/plain
and PUT
/PATCH
/DELETE
requests in set of blocked cross-origin requests for CSRF protection (bb2253d5
)
SubmitFunction
through ./$types
(#9201)fix: throw error when file can't be found in Vite manifest (#9558)
fix: make error.message
enumerable when sending ssrLoadModule
error to client (#9440)
fix: pass publicDir
Vite config in SSR (#9565)
fix: balance parentheses in error about wrong content type for action (#9513)
submitter
type to SumbitFunction
(#9484)feat: expose submitter in use:enhance SubmitFunction (#9425)
feat: add data-sveltekit-keepfocus and data-sveltekit-replacestate options to links (requires Svelte version 3.56 for type-checking with svelte-check
) (#9019)
fix: don't start debugger on 404s (#9424)
fix: handle srcset attributes with newline after comma (#9388)
fix: allow tsconfig to extend multiple other tsconfigs (#9413)
chore: update Undici to 5.21.0 (#9417)
feat: pause on debugger when falling back to full page reload during development (#9305)
feat: expose base
via $service-worker
, make paths relative (#9250)
fix: don't automatically prerender non-SSR'd pages (#9352)
fix: use 308 responses for trailing slash redirects, instead of 301s (#9351)
fix: remove buggy cookie path detection (#9298)
fix: don't prevent beforeNavigate
callbacks from running following a cancelled unloading navigation (#9347)
fix: persist DOM state on beforeunload (#9345)
fix: redirect to path with/without trailing slash when previewing prerendered pages (#9353)
fix: avoid FOUC when using CSS modules in dev (#9323)
fix: don't skip required parameters after missing optional parameters (#9331)
fix: account for server-emitted assets when prerenering (#9349)
fix: deal with fast consecutive promise resolutions when streaming (#9332)
chore: replace deprecated property access in preparation for TS 5.0 (#9361)
fix: respect <base>
when crawling (#9257)
fix: scroll before resetting focus, to avoid flash of unscrolled content (#9311)
fix: omit hash from global during development (#9310)
cookies.getAll
(#9287)fix: always include <link rel="stylesheet">
, even for stylesheets excluded from Link headers (#9255)
fix: preserve form state when submitting a second time (#9267)
paths.relative
option to control interpretation of paths.assets
and paths.base
(#9220)@sveltejs/kit
to noExternal
for ssr build (#9242)api.methods
and page.methods
to builder.routes
(#9145)paths.base
(#9232)handle
(#9198)fix: include .mjs files in precompression (#9179)
fix: revert mjs extension usage by default, make it an option (#9179)
chore: dummy changeset to force a release (#9207)
fix: set public env before starting app (#8957)
fix: preload modules on Safari (#8957)
fix: make assets
work in client when app is served from a subfolder (#8957)
builder.writeClient()
(#9095)OPTIONS
server method (#8731)missing "./paths" specifier in "@sveltejs/kit" package
error occurring in all projects (#9050)fix: ssr defaults preventing minification for client build (#9012)
fix: client-side trailing slash redirect when preloading data (#8982)
docs: clarify that version.name
should be deterministic (#8956)
fix: correctly include exported http methods in allow header (#8968)
chore: polyfill File from node:buffer (#8925)
fix: provide helpful error/warning when calling fetch
during render (#8551)
fix: print useful error when subscribing to SvelteKit's stores at the wrong time during SSR (#8960)
fix: ignore external links when automatically preloading (#8961)
chore: refactor fallback generation (#8972)
paths.assets
to paths.base
(#8928)fix: pick up config from endpoints (#8933)
fix: don't reuse previous server load cache when there's no server load function (#8893)
fix: deduplicate paths in tsconfig (#8880)
docs: clarify version management feature (#8941)
feat: support route-level configuration (#8740)
feat: add snapshot mechanism for preserving ephemeral DOM state (#8710)
fix: ensure types of all form actions are accessible even if differing (#8877)
fix: correctly handle HttpErrors on the client side (#8829)
docs: discourage use of goto
with external URLs (#8837)
fix: prevent crawling empty urls (<img src="">
) (#8883)
fix: correctly serialize request url when using load fetch
(#8876)
fix: ensure endpoints can fetch endpoints on the same host but not part of the application (#8869)
fix: only show prerendering message when actually prerendering (#8809)
fix: handle anchors with special chars when navigating (#8806)
fix: await finalise hook and run it only once (#8817)
fix: allow rest parameters to follow multiple optional - or not - parameters (#8761)
fix: consider headers when constructing request hash (#8754)
docs: fix typo (#8790)
fix: build error on layout with missing leaves (#8792)
fix: handle hash links with non-ASCII characters when navigating (#8767)
process.env
to child process (#8777)fix: only fetch __data.json
files for routes with a server load
function (#8636)
fix: add ignoreDeprecations
flag for TS 5.x (#8718)
fix: install polyfills when analysing code (#8636)
chore: restrict methods allowed for POST (#8721)
fix: provide proper error when POSTing to a missing page endpoint (#8714)
feat: add text(...)
helper for generating text responses (#8371)
feat: enable access to public env within app.html (#8449)
fix: add Content-Length
header to SvelteKit-generated responses (#8371)
+error.svelte
components (#8593)fix: correct link in types documentation (#8557)
fix: correctly detect changed data (#8377)
fix: only generate type definitions with sync
command (#8552)
fix: remove baseUrl to prevent wrong TypeScript auto imports if possible (#8568)
.svelte
files or missing <slot />
in layout is detected (#8475)fix: exit postbuild step with code 0 (#8514)
fix: only run missing page check in dev mode (#8515)
fix: avoid input name clobbering form method check (#8471)
fix: exclude service worker from tsconfig (#8508)
fix: provide better error message in case of missing +page.svelte
(#8478)
fix: make prerendered endpoint callable from non-prerendered server load (#8453)
docs: add links to http status codes (#8480)
fix: prerender page when prerender set to 'auto' and ssr set to true (#8481)
fix: prevent false positive warnings for fetch uses in firefox (#8456)
fix: check version on node fetch fail (#8487)
fix: avoid unnecessary $page store updates (#8457)
<a>
elements with no href
attribute when refocusing after navigation (#8418)fetch
in server load functions (#8420)assetFileNames
to worker rollup options (#8384)fetch
is used with relative URL (#8370)updated.check()
type changed to Promise<boolean>
(#8400)<link>
elements (#8369)*.test.js
and *.spec.js
files in params
directory (#8250)$page.route
has the correct shape (#8359)event.platform
to be possibly undefined (#8232)<form method="get">
(#8273)filterSerializedResponseHeaders
error message (#8348)First major release, see below for the history of changes that lead up to this. Starting from now all releases follow semver and changes will be listed as Major/Minor/Patch
$page.status
when using enhance
and result is of type 'error'
(#8073)builder.generateFallback(fallback)
(#8013)sveltekit()
return a promise of array of Vite plugins (#7994)__data.json
from url (#7979)+(layout|page)(.server)?.js
and +server.js
files (#7878)enhance
error message when form action doesn't exist or csrf is enabled (#7958)magic-string
(#7931)<form method="GET">
(#7828)data-sveltekit-prefetch
with -preload-code
and -preload-data
(#7776)prefetch
to preloadData
and prefetchRoutes
to preloadCode
(#7776)format
option from generateManifest(...)
(#7820)getStaticDirectory()
from builder API (#7809)prerendering
to building
, remove config.kit.prerender.enabled
(#7762)config.kit.outDir
able to be located in node_modules
(#7707)trailingSlash
a page option, rather than configuration (#7719)$app/environment
(#7689)Accept
and Accept-Language
headers when making a self-request (#7722)Access-Control-Allow-Origin: *
to static assets in dev (#7688)keepfocus
and noscroll
in goto
options if correctly-cased options are also present (#7678)%sveltekit.body%
is direct child of <body>
(#7652)beforeNavigate
description — routeId
-> route.id
(#7643)enhance
action (#7629)enhance
action parameter (#7608)--watch
(#7516)__data.json
requests (#7532)config.kit.prerender.onError
to handleHttpError
, and check for invalid fragment links (#7375)req.url
to req.originalUrl
in dev and preview (#7343)load
is a non-POJO (#7386)$types
to includes for better DX (#7301)config.kit.files.routes
(#7223)throw invalid()
in form actions (#7225)fetch
to RequestEvent
(#7113)fetch
in load
(#7065)FormData
polyfill from undici
rather than node-fetch
(#7065)update
to use:enhance
callback (#7083)RequestEvent
to $types
when +layout.server.js
present (#7063)never
, notice moved/deleted files (#7002)config.kit.env.dir
when running vite preview
(#7001)use:enhance
(#6828)svelte-kit sync
in all workspace directories during postinstall (#6949)getRequest
fails (#6936)write_types
on windows using posixify() (#6913)__data.js
files (#6904)href
attributes when crawling (#6891)@types/cookie
dependency (#6818)write_types
on windows (#6843)cookies
fixes and improvements (#6811)paths.base
and import
assets (#6769)$lib/server
modules in client-facing code (#6623)<button formaction>
(#6633)SubmitFunction
type (#6613)form
prop to pages (#6611)POST
/PUT
/PATCH
/DELETE
in +page.server.js
with export const actions
(#6469)filterSerializedResponseHeaders
resolve
option (#6569)$env/dynamic/*
in Vite ecosystem tools (#6454)externalFetch
with handleFetch
(#6565)rollupOptions.output.hoistTransitiveImports
by default (#6560)type
to navigation object (#6537)data-sveltekit-prefetch
. Warn like before when calling prefetch()
for external URLs. (#6518)invalidate(fn)
predicates with a URL instead of a string (#6493)*/*
(#6497)data-sveltekit-prefetch/noscroll/reload
to all child <a>
elements (#6442)ssr/hydrate/router/prerender.default
are now configurable in +page(.server).js
and +layout(.server).js
(#6197)error.html
page, rename kit.config.files.template
to kit.config.files.appTemplate
(#6367)router
/hydrate
page options with csr
(#6446)prerender = 'auto'
option, and extend prerender
option to endpoints (#6392)sveltekit:*
with valid HTML attributes like data-sveltekit-*
(#6170)/
when root +layout.server.js
exports load
(#6405)load
return values (#6318)$app/env
to $app/environment
, to disambiguate with $env/...
(#6334)$page.data
unnecessarily (#6311)errors
prop on all layout/leaf components, not just page that happens to be deepest (#6279)@
route breakouts to layouts in [foo]
or (foo)
directories (#6224)$types
for a route with a layout, leaf or endpoint (#6222)$env/*/private
in client (#6018)$app/stores
to be used from anywhere on the browser (#6100)enumerable: false
on "[x] no longer exists" getters so that they are not triggered by spreading (#6105)@
symbol (#6110)LayoutServerLoad.{name}
type (#6123)export let data
(#6050)+page.server.js
to respond to GET
requests with JSON (#6007)throw error/redirect
in +server.js
(#6028)set-cookie
in setHeaders
(#6033)export const prerender = false
in +page.server.js
(#6012)@sveltejs/kit
project in Vite 3.0.3+ (#5861)POST
handler provides a location
(#5989)__data.json
files for server-side redirects when prerendering (#5997)$env/static/*
are now virtual to prevent writing sensitive values to disk (#5825)Content-Length
header from being incorrectly inherited by requests made from load
's fetch
during SSR (#5922)AwaitedProperties
(#5917).js
(#5907)publishConfig.directory
from generated package.json (#5848)sveltekit
Vite plugin (#5839)$env/*/private
imports and Illegal module analysis in dev ignores non-js|ts|svelte files (#5739)@sveltejs/kit
types in ambient file (#5745)$env/static/private
, $env/static/public
, $env/dynamic/private
and $env/dynamic/public
modules (#5663)publicDir
option (#5648)d02f1f25
)_app
to client (#5620)__layout
returns error while rendering full error page (#4665)vite
key from config definition (#5530)Connection
header from being incorrectly inherited by requests made from load
's fetch
during SSR (#5393)$app/navigation#goto
(#5282)goto(href)
to goto(url)
(#5286)server
and prod
env variables (#5251)kit.browser.hydrate
(#5178)__data.json
for standalone endpoints (#5149)KitConfig
type (#5141)__data.json
request with trailingSlash: 'always'
(#5149)BodyValidator
handling for nested object literals (#5118)credentials
to undefined
in server-side fetch
(#5116)config.kit.files.routes
are added or deleted (#5076)engines
to specify that Node 16.7 is required (#5062)_app/immutable
with immutable cache header, not _app/version.json
(#5051)/favicon.ico
requests, handle them as a valid route (#5046)config.kit.alias
(#4964)svelte-kit sync
gracefully handles a nonexistent routes folder (#5020)%svelte.body%
with %sveltekit.body%
, etc. (#5016)outDir
, except for the generated
directory (#4997)viteServeStaticMiddleware
after server has attempted response (#4974)RequestEvent
and ResolveOptions
as public types (#4809)__types
directories (#4705)BodyValidator
for nested interfaces (#4939)RequestHandler
generics Body
validation (#4897)kit.prerender.entries
config (#4880)$service-worker
build, not just CSS (#4744)trailingSlash
for endpoint requests, apply trailingSlash
to pages consistently (#4699)--host
option to preview
exposes the server to both ipv4 and ipv6 networks (#4729)maxage
with cache
in LoadOutput
(#4690)invalidate
with predicate
function (#4636)props.page
when update or goto page (#4392)data-svelte
attribute to data-sveltekit
(#4641)load
dependencies
in LoadOutput
(#4536)platform
to requests triggered by fetch
in load
during SSR (#4599)static
directory from Vite's control (#4535)paths.base
is missing in dev (#4510)paths.base
when using --open
(#4510)__layout.reset
(#4388)__tests__
and __test__
in the routes directory (#4438)event.url.host
in dev mode when using --https
(#4364)event.routeId
and page.routeId
(#4345)InputProps
and OutputProps
to be typed separately in generated Load
(#4305)Output
to be typed in generated RequestHandler
(#4305)manifest.mimeTypes
part of the public API (#4302)prerendering
is correct (#4322)$lib
module (#4227)version.json
relative to paths.assets
, if set (#4234)svelte-kit preview
(#4207)body
instead of html
on navigation due to issues on Firefox (#4184)InputProps
and OutputProps
to be typed separately in Load
(#4160)load()
(#4128)tabindex="-1"
is no longer added to <body>
; <html>
only briefly receives it during navigation (#4140)RequestHandlerOutput
accepts body when it has or maybe is undefined
(#4152)__fetch_polyfill
to installFetch
, remove fetch exports (#4111)Page
type (#4076)mailto:
, tel:
) (#4072)__data.json
for pathnames with trailing slashes, including /
(#4066)transformPage
resolve option to return a promise (#4036)app.render
to server.respond
(#4034)Params
type argument for RequestHandler
(#3989)$page.url
to current URL in browser (#3942)event.url
consistent between server and client navigation (#3780)transformPage
option to resolve
(#3914)get
endpoint (#3816).DS_Store
in the default config for serviceWorker
(#3823)Headers
(#3829)createIndexFiles
option, derive from trailingSlash
instead (#3801)Host
header from being incorrectly inherited by requests made from load
's fetch
during SSR (#3690)url
store from $app/stores
ambient types (#3640)config.kit.hydrate
and config.kit.router
to config.kit.browser
(#3578)prerender.createIndexFiles
option (#2632)svelte-kit package
gives clearer error message when svelte2tsx and typescript are not installed (#3562)svelte-kit package
errors when lib directory does not exist (#3562)dev --https
works again (#3553)EndpointOutput
generic (#3537)svelte-kit package
only encodes text files (#3522)method
, headers
, and body
now accessed through request
field (docs, #3384)app.render
signature to (request: Request) => Promise (#3384)config.kit.ssr
and export const ssr
in favour of ssr
parameter for resolve
function in handle
(#2804)svelte-kit package
(#3161)disableScrollHandling
function (see https://svelte.dev/docs/kit/modules#$app-navigation) (#3182)Headers
instance in server-side fetch
(#3034)config.kit.prerender.concurrency
setting (#3120)<Route> received an unexpected slot "default"
warning (#3115)sveltekit:prefetch
mouse detection (#2995)event.composedPath
to find anchors for prefetching and routing (#2769)page.path
and page.params
during SSR (#2597)init
(#2544)strict.port: false
option (#2507)context
parameter of the load function to stuff
(#2439)kit.paths.base
was set. (#2407)import.meta.env
usage in $app/stores.js
to use $app/env.js
to DRY code and make mocking easier (#2353).js
extensions in package exports field (#2345)@sveltejs/kit
to noExternal
in dev server as well (#2332)@sveltejs/kit
to noExternal to resolve hooks module in dev server (#2306)EndpointOutput
response body objects to have a toJSON
property (#2170)force
to onError
in prerender config options (#2030)prerender.force
option in favor of prerender.onError
(#2007)scroll-*
CSS properties (#1972)Error
instance (#1811)svelte-kit package
(#1747)router
and hydration
disabled (#1724)engines
constraint (#1696)base
path is set and validate that option's value (#1666)content-length
limit respected; handle getRawBody
error(s) (#1528)polka
and sirv
dependency versions (#1548)navigating
store type (#1322)start
to preview
in the CLI and package scriptshandle
hook from positional arguments to named arguments (#959)_.config.js
to _.config.cjs
(#356)Вы можете оставить комментарий после Вход в систему
Неприемлемый контент может быть отображен здесь и не будет показан на странице. Вы можете проверить и изменить его с помощью соответствующей функции редактирования.
Если вы подтверждаете, что содержание не содержит непристойной лексики/перенаправления на рекламу/насилия/вульгарной порнографии/нарушений/пиратства/ложного/незначительного или незаконного контента, связанного с национальными законами и предписаниями, вы можете нажать «Отправить» для подачи апелляции, и мы обработаем ее как можно скорее.
Опубликовать ( 0 )