Skip to content

Commit

Permalink
Fix wrong LayoutServerLoad.name type (#6123)
Browse files Browse the repository at this point in the history
* fix typos

* add changeset
  • Loading branch information
iceghost committed Aug 20, 2022
1 parent ed013a9 commit fc16ed3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/tidy-mice-kick.md
@@ -0,0 +1,5 @@
---
'@sveltejs/kit': patch
---

Fix typos in generating `LayoutServerLoad.{name}` type
2 changes: 1 addition & 1 deletion packages/kit/src/core/sync/write_types.js
Expand Up @@ -363,7 +363,7 @@ function write_types_for_dir(config, manifest_data, routes_dir, dir, groups, ts)
}
if (server_load) {
server_load_exports.push(
`export type ${name}<OutputData extends Record<string, any> | void = Record<string, any> | void> = ${load};`
`export type ${name}<OutputData extends Record<string, any> | void = Record<string, any> | void> = ${server_load};`
);
server_load_event_exports.push(
`export type ${name} = Parameters<LayoutServerLoad.${name}>[0];`
Expand Down

0 comments on commit fc16ed3

Please sign in to comment.