FileList is undefined in client component
Unanswered
Chesapeake Bay Retriever posted this in #help-forum
Chesapeake Bay RetrieverOP
Next.js 14 App Router.
Hey guys I have a client component and a zod form schema
i have a input with type="file"
one of the fields in my zod schema is z.instanceof(FileList) since input type="file" actually returns FileList
However, I am getting FileList is undefined I know FileList is sometyhing that only exists in the Browser but my component is client component? how is it not picking up FileList?
Hey guys I have a client component and a zod form schema
i have a input with type="file"
one of the fields in my zod schema is z.instanceof(FileList) since input type="file" actually returns FileList
However, I am getting FileList is undefined I know FileList is sometyhing that only exists in the Browser but my component is client component? how is it not picking up FileList?