Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Zig ZON › zzon

zzon logo

npm Build status

A fast, spec-compliant ZON parser and serializer for JavaScript.

ZON is a compact, human-readable, and easy-to-parse data format from the Zig programming language that is similar to JSON in JavaScript.

The API is similar to the native JSON API.

Try it in the Playground

Installation

npm install zzon

Usage

Stringify

import { ZON } from 'zzon';

const zon = ZON.stringify({"a":1,"b":"abc","c":true});
console.log(zon); // .{.a=1,.b="abc",.c=true}

Parse

import { ZON } from 'zzon';

const json = ZON.parse(`.{.a=1,.b="abc",.c=true}`);
console.log(json); // {"a":1,"b":"abc","c":true}

zzon playground demo

Benchmarks

Performance comparison between ZON and JSON (source: test/index.test.ts):

Operation JSON ZON Difference
Parse 430.80 MB/s 38.66 MB/s 11.04x slower
Stringify 454.94 MB/s 87.43 MB/s 5.15x slower

Hardware: Apple M1 Pro
Platform: darwin 25.0.0 (arm64)

Last updated: 2025-10-24T03:55:48.380Z

Example Usage

License

MIT

About

A fast, spec compliant, ZON parser and serializer for JavaScript.

Topics

Resources

Stars

Watchers

Forks

Releases

Used by

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.