describeValue
describeValue(
value):string
Defined in: packages/core/src/merkle-dag-serialization.ts:81
Human-readable label for an unknown value’s runtime type, used in wire validation error messages.
typeof alone reports 'object' for both null and arrays, which
obscures common malformed-peer cases. This helper distinguishes those:
null->'null'- any array ->
'array' - anything else -> raw
typeofresult ('object','string','number','boolean','undefined', etc.)
Use in validation error strings whenever a field’s expected type is not already enforced to be a primitive, so error attribution back to the peer is unambiguous.
Parameters
Section titled “Parameters”unknown
Returns
Section titled “Returns”string