Test for deep equality - Node.js `assert.deepStrictEqual()` algorithm as a standalone module
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.dockerignore
.editorconfig
.gitattributes
.gitignore
.travis.yml
index.js
license
package.json
readme.md
test.js

readme.md

deep-strict-equal Build Status

Test for deep equality - Node.js assert.deepStrictEqual() algorithm as a standalone module

Issues and improvements should be done in Node.js first.

Install

$ npm install --save deep-strict-equal

Usage

const deepStrictEqual = require('deep-strict-equal');

deepStrictEqual({foo: {bar: [1, 2]}}, {foo: {bar: [1, 2]}});
//=> true

deepStrictEqual({foo: {bar: [1, 2]}}, {foo: {bar: [1, 4]}});
//=> false

deepStrictEqual({foo: {bar: 1}}, {foo: {bar: 1}});
//=> true

deepStrictEqual({foo: {bar: 1}}, {foo: {bar: '1'}});
//=> false

License

MIT © Sindre Sorhus