Skip to content

Latest commit

Β 

History

History
28 lines (20 loc) Β· 643 Bytes

File metadata and controls

28 lines (20 loc) Β· 643 Bytes

BytesIO πŸš€

A simple Buffer implementation inspired by Python's BytesIO.
This project was originally based on the source code from @tgsnake/core. 🐍

Features ✨

  • In-memory byte stream operations πŸ’Ύ
  • Read and write bytes efficiently ⚑
  • Python-like API for ease of use 🐍

Installation πŸ“¦

# Example installation command
npm install @tgsnake/bytesio

Usage πŸ› οΈ

import { BytesIO } from '@tgsnake/bytesio';

const stream = new BytesIO();
stream.write(Buffer.from([1, 2, 3]));
stream.seek(0);
console.log(stream.read(3)); // Output: <Buffer 01 02 03>