Skip to content

Sveltekit handleSubmit sends back data as undefined #2796

Closed
@ghoshsanjoy78

Description

@ghoshsanjoy78

Description

The issue 1270 is still happening.

On the client side, I am calling handleSubmit like so -
handleSubmit(e, { data: { options: dataToSendBack } });

On the server side in /api/chat/+server.ts file when I check the data property on request, it comes through the first time but all subsequent calls, comes through as undefined

const { messages, data } = await request.json(); console.log(data) // Shows as undefined except the first time

Code example

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    ai/uibugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions