Open bduff9 opened 1 month ago
I would expect anything defined with a zod schema to be defined per that schema, such as in the zsa library.
Currently, using the code below, invoicePath comes out as any despite it being defined as a string in my schema.
import { createSafeRoute } from 'next-safe-route'; import { z } from 'zod'; const querySchema = z.object({ invoicePath: z.string(), }); export const GET = createSafeRoute() .query(querySchema) .handler(async (_, context) => { const { invoicePath } = context.query; ... });
@bduff9 Hey, just released v0.0.20, could you check if this is still an issue? Thanks!
Expected Behavior
I would expect anything defined with a zod schema to be defined per that schema, such as in the zsa library.
Actual Behavior
Currently, using the code below, invoicePath comes out as any despite it being defined as a string in my schema.
Steps to Reproduce the Problem
Specifications