-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
submitter is not typed in packages/kit/types/index.d.ts SubmitFunction arguments #9483
Copy link
Copy link
Closed
Description
Describe the bug
A submitter argument is available in the SubmitFunction however the type is missing in index.d.ts. The type has already been added to the documentation and packages/kit/types/ambient.d.ts but the SubmitFunction is duplicated due to a likeyly bug in TS (related).

The original feature was added here.
Reproduction
This can be seen in any SvelteKit app that uses a SubmitFunction and destructures submitter from the input arguments.
Logs
Property 'submitter' does not exist on type '{ action: URL; data: FormData; form: HTMLFormElement; controller: AbortController; cancel(): void; }'.ts(2339)
System Info
System:
OS: macOS 13.2.1
CPU: (10) arm64 Apple M1 Max
Memory: 3.86 GB / 32.00 GB
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 19.7.0 - /usr/local/bin/node
Yarn: 1.22.19 - /usr/local/bin/yarn
npm: 9.5.1 - /usr/local/bin/npm
Watchman: 20221009.103647.0 - /usr/local/bin/watchman
Browsers:
Brave Browser: 111.1.49.120
Safari: 16.3
npmPackages:
@sveltejs/adapter-auto: ^2.0.0 => 2.0.0
@sveltejs/kit: ^1.5.0 => 1.13.0
svelte: ^3.46.0 => 3.57.0
vite: ^4.0.3 => 4.2.1Severity
annoyance
Additional Information
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels