Skip to content

Commit

Permalink
this is out of date
Browse files Browse the repository at this point in the history
  • Loading branch information
Rich-Harris committed Dec 10, 2023
1 parent fcbd536 commit 7b5b9d5
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions documentation/docs/20-core-concepts/20-load.md
Original file line number Diff line number Diff line change
Expand Up @@ -283,8 +283,6 @@ For example, if SvelteKit is serving my.domain.com:

Other cookies will not be passed when `credentials: 'include'` is set, because SvelteKit does not know which domain which cookie belongs to (the browser does not pass this information along), so it's not safe to forward any of them. Use the [handleFetch hook](hooks#server-hooks-handlefetch) to work around it.

> When setting cookies, be aware of the `path` property. By default, the `path` of a cookie is the current pathname. If you for example set a cookie at page `admin/user`, the cookie will only be available within the `admin` pages by default. In most cases you likely want to set `path` to `'/'` to make the cookie available throughout your app.
## Headers

Both server and universal `load` functions have access to a `setHeaders` function that, when running on the server, can set headers for the response. (When running in the browser, `setHeaders` has no effect.) This is useful if you want the page to be cached, for example:
Expand Down

0 comments on commit 7b5b9d5

Please sign in to comment.