Type Alias: FieldType
type FieldType =
| {
kind: "scalar";
scalar: ScalarType;
}
| {
kind: "enum";
ref: string;
}
| {
hint?: string;
kind: "unknown";
}
| {
kind: "ref";
ref: string;
}
| {
kind: "map";
value: FieldType;
}
| {
element: FieldType;
kind: "array";
}
| {
discriminator?: {
mapping?: Record<string, string>;
propertyName: string;
};
kind: "union";
variants: FieldType[];
};
Defined in: packages/ir/src/types.ts:36
Hand-written because FieldTypeSchema is recursive (union variant) and
v.lazy needs an explicit type — same pattern as JsonValue.
ref is a bare name resolved against the same source (entities then
typeAliases); there is no namespace qualifier in v1.