Skip to content

ReferenceError: FormData is not defined - SSR POST request #106

@Grandnainconnu

Description

@Grandnainconnu

Hello,

There is a problem to find basic types during SSR request in nextjs getServerSideProps.
It appears that Node has some problems to validate basic types, FormData and Blob.

Request tried:

export const listFromCategory = ({ categorySlug, limit = 24, page = 1 }: { categorySlug: string, limit?: number, page?: number }): Action => ({
    method: 'POST',
    endpoint: `/products/list/limit/${limit}/page/${page}`,
    body: {
        domain: {
            type: 'category',
            value: categorySlug,
        },
    },
    credentials: 'omit',
});

Is there something that I'm doing wrongly?

Thank you in advance.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions