Skip to content

Use Zod v4 registry to get model registration info #303

@WilliamABradley

Description

@WilliamABradley

The new .meta() function in zod v4 could be a nice way to be able to collect metadata for gqloom registration.

E.g.

export const SortDirection = z
  .enum(["ASC", "DESC"])
  .meta({ id: "SortDirection" });
export type SortDirection = z.infer<typeof SortDirection>;

I would expect the meta.id would be able to register with gqloom with a name of "SortDirection"

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions