# @elijahjcobb/better-json

> This package adds some functionality to `JSON.parse()` and `JSON.stringify()` adding the ability to parse and stringify a `Buffer` object automatically recursively.

Latest version **1.0.0** (published 2020-04-18) · MIT license · 0 weekly downloads

## Install

```sh
npm install @elijahjcobb/better-json
pnpm add @elijahjcobb/better-json
yarn add @elijahjcobb/better-json
bun add @elijahjcobb/better-json
```

## Health

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

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

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2020-04-18 |
| First published | 2020-04-18 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 8.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Elijah Cobb |
| Maintainers | ejc |

## Links

- npm: https://www.npmjs.com/package/@elijahjcobb/better-json
- Repository: https://github.com/elijahjcobb/better-json
- Homepage: https://github.com/elijahjcobb/better-json#readme
- Issues: https://github.com/elijahjcobb/better-json/issues
- npm.io page: https://npm.io/package/@elijahjcobb/better-json

## Recent versions

- 1.0.0 (latest) — 2020-04-18

## README

# better-json
This package adds some functionality to `JSON.parse()` and `JSON.stringify()` adding the ability to parse and stringify
a `Buffer` object automatically recursively.

## Example
```typescript
import {BetterJSON} from "@elijahjcobb/better-json";

const obj: { email: string, security: { salt: Buffer, pepper: Buffer } } = {
    email: "Elijah",
    security: {
         salt: Buffer.from("salt"),
         pepper: Buffer.from("pepper")
    }
};

const str: string = BetterJSON.stringify(obj);
const obj2: { email: string, security: { salt: Buffer, pepper: Buffer } } = BetterJSON.parse(str);

// obj === obj2
```

## Documentation
Everything is completely documented. You can view the
[declaration files](https://github.com/elijahjcobb/request/better-json/master/dts) or even the
[source code](https://github.com/elijahjcobb/better-json/tree/master/ts) on GitHub.

## Bugs
If you find any bugs please [create an issue on GitHub](https://github.com/elijahjcobb/better-json/issues) or if you
are old-fashioned email me at [elijah@elijahcobb.com](mailto:elijah@elijahcobb.com).

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