MissingKeyRepresents a schema issue produced when a required key or tuple index is missing from the input.
When to use
Use when you need to detect absent fields in struct/tuple validation.
Details
- Has no
actualvalue — getActual returnsOption.none(). annotationsmay contain a custommessageMissingKeyfor formatting.
Source effect/SchemaIssue.ts:31917 lines
export class class MissingKeyclass MissingKey {
_tag: 'MissingKey';
annotations: Schema.Annotations.Key<unknown> | undefined;
toString: (this: Issue) => string;
}
Represents a schema issue produced when a required key or tuple index is missing from the input.
When to use
Use when you need to detect absent fields in struct/tuple validation.
Details
- Has no
actual value —
getActual
returns Option.none().
annotations may contain a custom messageMissingKey for formatting.
MissingKey extends class BaseBase {
readonly MissingKey._tag: "MissingKey"_tag = "MissingKey"
/**
* The metadata for the issue.
*/
readonly MissingKey.annotations: anyThe metadata for the issue.
annotations: import SchemaSchema.declareAnnotations.type Schema.Annotations.Key = /*unresolved*/ anyKey<unknown> | undefined
constructor(
/**
* The metadata for the issue.
*/
annotations: anyThe metadata for the issue.
annotations: import SchemaSchema.declareAnnotations.type Schema.Annotations.Key = /*unresolved*/ anyKey<unknown> | undefined
) {
super()
this.MissingKey.annotations: anyThe metadata for the issue.
annotations = annotations: anyThe metadata for the issue.
annotations
}
}Referenced by 2 symbols