# circ-json

> Json (=readable) inspired serializer.

Latest version **1.0.4** (published 2023-06-05) · ISC license · 0 weekly downloads

## Install

```sh
npm install circ-json
pnpm add circ-json
yarn add circ-json
bun add circ-json
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.4 |
| Published | 2023-06-05 |
| First published | 2023-02-24 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 14.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | maximilianMairinger |
| Maintainers | zzrv |
| Keywords | circular, circ, recursive, json, object, serializer |

## Links

- npm: https://www.npmjs.com/package/circ-json
- Repository: https://github.com/maximilianMairinger/circJson
- Homepage: https://github.com/maximilianMairinger/circJson#readme
- Issues: https://github.com/maximilianMairinger/circJson/issues
- npm.io page: https://npm.io/package/circ-json

## Alternatives

- [@mapbox/jsonlint-lines-primitives](https://npm.io/package/@mapbox/jsonlint-lines-primitives.md) — 5.3M weekly downloads
- [reftools](https://npm.io/package/reftools.md) — 3.5M weekly downloads
- [@hey-api/openapi-ts](https://npm.io/package/@hey-api/openapi-ts.md) — 3.5M weekly downloads
- [@mapbox/geojson-rewind](https://npm.io/package/@mapbox/geojson-rewind.md) — 2.4M weekly downloads
- [turbo-stream](https://npm.io/package/turbo-stream.md) — 1.7M weekly downloads

## Recent versions

- 1.0.4 (latest) — 2023-06-05
- 1.0.3 — 2023-02-26
- 1.0.2 — 2023-02-25
- 1.0.1 — 2023-02-25
- 1.0.0 — 2023-02-25
- 0.0.1 — 2023-02-24

## README

# Circ json

Json (readable) inspired serializer for cyclic objects.

## Installation

```shell
 $ npm i circ-json
```

## Usage

Analog to `JSON`

```ts
import { stringify, parse } from "circ-json"

const c = {
  a: 1,
  b: {i: 1}
}

c.c = c
c.bb = c.b

const s = stringify(c) //{"a":1,"b":{"i":1},"c":{"$ref":"#"},"bb":{"$ref":"#/b"}}

deepEqual(parse(s), c) // true
```

## Contribute

All feedback is appreciated. Create a pull request or write an issue.

---
_Source: https://npm.io/package/circ-json · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
