Options
All
  • Public
  • Public/Protected
  • All
Menu

This module exports the @base64 and @hex modules and it's the one used when importing the package with import 'arraybuffer-encoding'. You should consider using one of the submodules instead, such as import 'arraybuffer-encoding/hex' or import 'arraybuffer-encoding/base64'

Index

Variables

Variables

Base64

Base64: { Decode: (str: string) => ArrayBuffer; Encode: (ab: ArrayBuffer) => string } = ...

Base64 encoding and decoding utilities

Type declaration

  • Decode: (str: string) => ArrayBuffer
      • (str: string): ArrayBuffer
      • Decode a string from base64, using base64 "standard" encoding. Padding is always optional.

        Parameters

        • str: string

          Base64-encoded string

        Returns ArrayBuffer

        Data decoded from the base64 string

  • Encode: (ab: ArrayBuffer) => string
      • (ab: ArrayBuffer): string
      • Encode an ArrayBuffer to base64 in a string, using base64 "standard" encoding.

        Parameters

        • ab: ArrayBuffer

          Data to encode to base64

        Returns string

        Base64-encoded string

Hex

Hex: { Decode: (str: string) => ArrayBuffer; Encode: (ab: ArrayBuffer) => string } = ...

Hex encoding and decoding utilities

Type declaration

  • Decode: (str: string) => ArrayBuffer
      • (str: string): ArrayBuffer
      • Decode a string from hex.

        Parameters

        • str: string

          Hex-encoded string

        Returns ArrayBuffer

        Data decoded from the hex string

  • Encode: (ab: ArrayBuffer) => string
      • (ab: ArrayBuffer): string
      • Encode an ArrayBuffer to hex in a string.

        Parameters

        • ab: ArrayBuffer

          Data to encode to hex

        Returns string

        Hex-encoded string

Generated using TypeDoc