deep-equal-json

`deep-equal`, but only for JSON-supported values.

MIT 2 个版本
安装
npm install deep-equal-json
yarn add deep-equal-json
pnpm add deep-equal-json
bun add deep-equal-json
README

deep-equal-json Version Badge

github actions coverage License Downloads

npm badge

deep-equal, but only for JSON-supported values.

Note that any results you get from values that do not round-trip through JSON.stringify and JSON.parse are explicitly not part of this API, and you must not rely on them.

Example

const assert = require('assert');
const deepEqual = require('deep-equal-json');

assert.equal(typeof deepEqual(a, b), 'boolean'); // `a` and `b` can be anything that roundtrips with JSON

Tests

Simply clone the repo, npm install, and run npm test

版本列表
1.0.1 2024-12-12
1.0.0 2023-06-06