@oslojs/encoding
TypeScript icon, indicating that this package has built-in type declarations

0.3.0 • Public • Published

@oslojs/encoding

Documentation: https://encoding.oslojs.dev

A JavaScript library for encoding and decoding data with hexadecimal, base32, base32hex, base64, and base64url schemes.

  • Runtime-agnostic
  • No third-party dependencies
  • Fully typed
import { base64 } from "@oslojs/encoding";

const data: Uint8Array = new TextEncoder().encode("hello world");
const encoded = base64.encode(data);
const decoded = base64.decodeIgnorePadding(encoded);

Alongside @oslojs/binary and @oslojs/crypto, it aims to provide a basic toolbox for implementing auth and auth-related standards.

Installation

npm i @oslojs/encoding

Dependencies (0)

    Dev Dependencies (9)

    Package Sidebar

    Install

    npm i @oslojs/encoding

    Weekly Downloads

    2,333

    Version

    0.3.0

    License

    MIT

    Unpacked Size

    16.2 kB

    Total Files

    11

    Last publish

    Collaborators

    • pilcrowonpaper