JSPM

  • Created
  • Published
  • Downloads 207
  • Score
    100M100P100Q79808F
  • License MIT

Zero-copy Buffer reader and writer

Package Exports

  • @hazae41/binary

Readme

Zero-copy Buffer reader and writer 🏎️

npm i @hazae41/binary

Node Package 📦

Current features

  • 100% TypeScript and ESM
  • Zero-copy reading and writing
  • No external dependency
  • Unit tested

Usage

const binary = Binary.alloc(3)
const binary = Binary.allocUnsafe(3)
const binary = new Binary(Buffer.from([0x1, 0x2]))
binary.writeUint8(123)
binary.writeUint16(1234)