MCPcopy Create free account
hub / github.com/ProNextJS/declarative-routing / getRequireds

Function getRequireds

assets/shared/utils.ts:49–60  ·  view source on GitHub ↗
(shape: z.ZodRawShape)

Source from the content-addressed store, hash-verified

47}
48
49function getRequireds(shape: z.ZodRawShape) {
50 const keys: string[] = [];
51 for (const key in shape) {
52 const fieldShape = shape[key];
53 if (
54 !(fieldShape instanceof z.ZodDefault) &&
55 !(fieldShape instanceof z.ZodOptional)
56 )
57 keys.push(key);
58 }
59 return keys;
60}
61
62function parseShape(
63 shape: z.ZodRawShape,

Callers 1

processSchemaFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected