Asynchronously parses the input using the provided Zod schema (v3 or v4) and returns a safe parse result. This function handles both Zod v3 and v4 schemas, returning a result object indicating success or failure.
interopSafeParseAsync<T>(
schema: InteropZodType<T>,
input: unknown
): Promise<InteropZodSafeParseResult<T>>| Name | Type | Description |
|---|---|---|
schema* | InteropZodType<T> | The Zod schema (v3 or v4) to use for parsing. |
input* | unknown | The input value to parse. |