Zod config validation (#635)

* Zod WIP

* Zod form validation

* DynamicForm testing

* Fix linting

* Delete rasterSource.ts

---------

Co-authored-by: philon- <philon-@users.noreply.github.com>
This commit is contained in:
Jeremy Gallant
2025-06-04 08:10:59 -04:00
committed by GitHub
co-authored by philon-
parent df036d3904
commit 1cbd98ec53
61 changed files with 1751 additions and 1263 deletions
+2 -2
View File
@@ -1,7 +1,7 @@
import { ZodError, ZodSchema } from "zod";
import { ZodError, ZodType } from "zod/v4";
export function validateSchema<T>(
schema: ZodSchema<T>,
schema: ZodType<T>,
data: unknown,
): { success: true; data: T } | { success: false; errors: ZodError["issues"] } {
const result = schema.safeParse(data);