@vandeurenglenn/typed-array-smart-deconcat
TypeScript icon, indicating that this package has built-in type declarations

1.0.3 • Public • Published

typed-array-smart-deconcat

TypedArray.set() the smartDeconcat() way

install

npm i @vandeurenglenn/typed-array-smart-deconcat

usage

deconcat

import typedArraySmartDeconcat from '@vandeurenglenn/typed-array-smart-deconcat'

const deconcated = typedArraySmartDeconcat(concated)

console.log(new TextDecoder().decode(deconcated[0])) // hello
console.log(new TextDecoder().decode(deconcated[1])) // world

concat

import typedArraySmartConcat from '@vandeurenglenn/typed-array-smart-concat'

const concated = typedArraySmartConcat([
  new TextEncoder('hello'),
  new TextEncoder('world')
])

console.log(new TextDecoder().decode(concated)) // <length><value><length><value>

Readme

Keywords

Package Sidebar

Install

npm i @vandeurenglenn/typed-array-smart-deconcat

Weekly Downloads

2

Version

1.0.3

License

MIT

Unpacked Size

5.89 kB

Total Files

10

Last publish

Collaborators

  • vandeurenglenn