@blockchaincommons/dcbor - v1.0.0-beta.1
    Preparing search index...

    Function expectTaggedContent

    • Extract content if has specific tag, throwing if not.

      Throws { type: "WrongType" } if cbor is not tagged at all, otherwise { type: "WrongTag", expected, actual } if the tag doesn't match.

      Parameters

      • cbor: Cbor

        CBOR value

      • tag: number | bigint

        Expected tag value

      Returns Cbor

      Tagged content