Skip to content

assertCodecIsType

assertCodecIsType(codec, types): void

Checks nested codec types against a type description string. Uses codec.toRawType() internally.

Parameters

codec: Codec

The codec to type check.

types

An array of strings denoting types to check against.

Returns

void

Throws

TypeError If codec type is not contained in the allowed types.

Source

utils/src/Decode.ts:30