UNPKG

707 BTypeScriptView Raw
1import type { U8aLike } from '../types.js';
2/**
3 * @name u8aConcat
4 * @summary Creates a concatenated Uint8Array from the inputs.
5 * @description
6 * Concatenates the input arrays into a single `UInt8Array`.
7 * @example
8 * <BR>
9 *
10 * ```javascript
11 * import { { u8aConcat } from '@polkadot/util';
12 *
13 * u8aConcat(
14 * new Uint8Array([1, 2, 3]),
15 * new Uint8Array([4, 5, 6])
16 * ); // [1, 2, 3, 4, 5, 6]
17 * ```
18 */
19export declare function u8aConcat(...list: readonly U8aLike[]): Uint8Array;
20/**
21 * @name u8aConcatStrict
22 * @description A strict version of [[u8aConcat]], accepting only Uint8Array inputs
23 */
24export declare function u8aConcatStrict(u8as: readonly Uint8Array[], length?: number): Uint8Array;