RequiredAtLeastOneOptions
Defined in: projects/ngx-signal-schema/src/lib/validators/required-at-least-one.ts:5
Type Parameters
Section titled “Type Parameters”T extends object
Properties
Section titled “Properties”attachTo?
Section titled “attachTo?”
optionalattachTo?: (p) =>SchemaPath<unknown>
Defined in: projects/ngx-signal-schema/src/lib/validators/required-at-least-one.ts:11
Optional selector to determine which field should receive the validation error. If omitted, the error is attached to all participating fields.
Parameters
Section titled “Parameters”SchemaPathTree<T>
Returns
Section titled “Returns”SchemaPath<unknown>
exclude?
Section titled “exclude?”
optionalexclude?: (p) =>SchemaPath<unknown>[]
Defined in: projects/ngx-signal-schema/src/lib/validators/required-at-least-one.ts:40
Optional list of fields to exclude from the “at least one” check.
This is useful in recursive mode to skip structural or metadata fields (like a discriminator field).
Parameters
Section titled “Parameters”SchemaPathTree<T>
Returns
Section titled “Returns”SchemaPath<unknown>
isFilled?
Section titled “isFilled?”
optionalisFilled?: (value) =>boolean
Defined in: projects/ngx-signal-schema/src/lib/validators/required-at-least-one.ts:17
Optional function to define what should count as “filled”.
By default, a value is considered filled if it is neither null nor an empty string ('').
Parameters
Section titled “Parameters”unknown
Returns
Section titled “Returns”boolean
message?
Section titled “message?”
optionalmessage?:string
Defined in: projects/ngx-signal-schema/src/lib/validators/required-at-least-one.ts:23
Optional custom validation error message.
recursive?
Section titled “recursive?”
optionalrecursive?:boolean
Defined in: projects/ngx-signal-schema/src/lib/validators/required-at-least-one.ts:33
Optional flag to enable recursive validation of nested objects.
If enabled, the validation will traverse nested objects and validate their properties as well. Otherwise, nested objects themselves are ignored and only direct leaf fields participate.
Defaults to true if no selectors are provided, and false otherwise.