We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
There is no zod validation scheme for the request body that uses form data
I want to have something like this
export const createPostSchema = z.object({ file: z.instanceof(File), // Validate file as a File object name: z.string(), // Name as a required string subtitle: z.string(), // Subtitle as a required string text: z.string(), // Text as a required string publishedAt: z.string().datetime(), // ISO 8601 date-time validation status: z.boolean(), // Boolean validation store: z.number().int(), // Integer validation fixed: z.boolean(), // Boolean validation imageAlt: z.string().optional(), // Optional string postTags: z.array(z.number().int()), // Array of integers });
No
There is no any problems with other endpoints that don’t use form data. Orval generates for me request body zod validation successfully
Example:
export const postV1RolesCreateBody = zod.object({ name: zod.string().min(1), title: zod.string().nullish(), rolePermissions: zod.array( zod.object({ id: zod.number().optional(), }) ), });
NextJs version: 13, Node version: 20, Orval version: 7.3.0
The text was updated successfully, but these errors were encountered:
No branches or pull requests
What are the steps to reproduce this issue?
What happens?
There is no zod validation scheme for the request body that uses form data
What were you expecting to happen?
I want to have something like this
Any logs, error output, etc?
No
Any other comments?
There is no any problems with other endpoints that don’t use form data. Orval generates for me request body zod validation successfully
Example:
What versions are you using?
NextJs version: 13, Node version: 20, Orval version: 7.3.0
The text was updated successfully, but these errors were encountered: