Skip to content

Graphorin API reference v0.1.0


Graphorin API reference / @graphorin/security / guardrails / maxLength

Function: maxLength()

ts
function maxLength<TValue>(opts): GuardrailDefinition<TValue>;

Defined in: packages/security/src/guardrails/builtins/max-length.ts:47

Construct a maxLength guardrail. Returns an input or output variant depending on the stage option.

Type Parameters

Type ParameterDefault type
TValueunknown

Parameters

ParameterType
optsMaxLengthOptions

Returns

GuardrailDefinition&lt;TValue&gt;

Stable