bytesMap
bytesMap(
bytes,map):Uint8Array<ArrayBuffer>
Defined in: packages/core/src/buffer/bytes-map.ts:13
Applies map to every octet of bytes, returning a new array.
The result of map is masked to one octet, so a caller may write ~byte
without restating & 0xff.
Complexity: O(n) time and O(n) memory in the input length.
Parameters
Section titled “Parameters”Uint8Array
The source octets.
(byte, index) => number
Called with each octet and its index.
Returns
Section titled “Returns”Uint8Array<ArrayBuffer>
A new array of the same length.