Core
struct.unknown
Struct that accepts any value except null and undefined, typed as unknown.
@defjs/core · Function
Signature
function unknown(): UnknownStruct;
The value is returned unchanged, and nothing inside it is validated or stripped.
-
Chain
.null(),.optional(), or.nullish()to acceptnullorundefined. -
The output type is
unknown, so the caller must narrow it before use.