refactor(core): derive all schema.ts leaves' .zod via effect-zod walker (#23754)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { Schema } from "effect"
|
||||
import z from "zod"
|
||||
|
||||
import { zod } from "@/util/effect-zod"
|
||||
import { withStatics } from "@/util/schema"
|
||||
|
||||
const projectIdSchema = Schema.String.pipe(Schema.brand("ProjectID"))
|
||||
@@ -10,6 +10,6 @@ export type ProjectID = typeof projectIdSchema.Type
|
||||
export const ProjectID = projectIdSchema.pipe(
|
||||
withStatics((schema: typeof projectIdSchema) => ({
|
||||
global: schema.make("global"),
|
||||
zod: z.string().pipe(z.custom<ProjectID>()),
|
||||
zod: zod(schema),
|
||||
})),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user