hex-to-array-buffer
TypeScript icon, indicating that this package has built-in type declarations

2.0.0 • Public • Published

hex-to-array-buffer

Turn a string of hexadecimal characters into an ArrayBuffer.

Installation

npm install --save hex-to-array-buffer

Usage

import hexToArrayBuffer from 'hex-to-array-buffer'

const buffer = hexToArrayBuffer('ceae96a325e1dc5dd4f405d905049ceb')

console.log(buffer)
//=> ArrayBuffer { byteLength: 16 }

API

hexToArrayBuffer(input)

  • input (string, required) - specified as a string of hexadecimal characters
  • returns ArrayBuffer - a new ArrayBuffer with the binary content from input

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 2.0.0
    665
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 2.0.0
    665
  • 1.1.0
    1,116
  • 1.0.0
    18
  • 0.1.0
    18

Package Sidebar

Install

npm i hex-to-array-buffer

Weekly Downloads

1,817

Version

2.0.0

License

MIT

Unpacked Size

4.18 kB

Total Files

7

Last publish

Collaborators

  • linusu