New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

packatoon

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

packatoon

Pack JSON collections as TOON like format

latest
Source
npmnpm
Version
0.2.0
Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

packatoon

Coverage Status

Social Media Photo by Agenlaku Indonesia on Unsplash

16 years ago I wrote json.hpack for PHP, JS and C#

14 years ago I re-wrote JSONH for Python, PHP and JS.

A few days ago TOON non-standard format came out.

packatoon module allows anyone to "pack" and "unpack" homogenous collections which is pretty much what any .csv file has done since about forever, except it remains JSON compatible like all previous work did before TOON came out.

As summary, this module simply uses modern JS to accomplish what TOON or JSONH before did without pretending to be, or do, anything else.

example

import { pack, unpack } from 'packatoon';

const collection = [
  { a: 1, b: 2 },
  { a: 3, b: 4 },
];

const packed = pack(collection);

// [2, 'a', 'b', 1, 2, 3, 4]

unpack(packed);
// [{a:1,b:2},{a:3,b:4}]

That's it.

Keywords

JSON

FAQs

Package last updated on 19 Nov 2025

Did you know?

Socket

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