Skip to content

Bytes.concat

Concatenates two or more Bytes.Bytes.

Imports

Named
import { Bytes } from 'ox'

Examples

import { Bytes } from 'ox'
 
const bytes = Bytes.concat(
  Bytes.from([1]),
  Bytes.from([69]),
  Bytes.from([420, 69]),
)
Uint8Array [ 1, 69, 420, 69 ]

Definition

function concat(
  values: readonly Bytes[],
): Bytes

Source: src/Bytes.ts

Parameters

values

  • Type: readonly Bytes[]

Values to concatenate.

Return Type

Concatenated Bytes.Bytes.

Bytes