Socket
Socket
Sign inDemoInstall

bootbuffer

Package Overview
Dependencies
1
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    bootbuffer

<a href="https://coveralls.io/github/heineiuo/bootbuff


Version published
Weekly downloads
9
increased by28.57%
Maintainers
1
Install size
62.0 kB
Created
Weekly downloads
 

Readme

Source

BootBuffer

GitHub Actions status Coverage status npm version Join the chat at https://gitter.im/heineiuo/bootbuffer

A binary-encoded serialization, for dababase columns, data transfer and others.

Get Started

import { BootBuffer } from 'bootbuffer' // install from npm

const bb = new BootBuffer()
bb.add('foo', 'bar')
bb.add('int8', 13)
bb.add('float', 13.2456741)
bb.add('double', 13.2456741123)
bb.add('json1', { foo: 'bar' })

for await (const entry of BootBuffer.read(bb.buffer)) {
  console.log(entry.key, entry.value)
  // foo, bar
  // int8, 13
  // float, 13.2456741
  // double, 13.2456741123
  // json1, { foo: "bar" }
}

Support types

  • buffer
  • string
  • uint8
  • uint16
  • uint32
  • bigint
  • float
  • double
  • boolean
  • json

Format

ValueType<varint> | KeyLength<varint> | ValueLength<varint> | Key<Buffer> | Value<Buffer> | ...repeat |

License

MIT License

FAQs

Last updated on 18 Jun 2020

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc