Deep comparison of two variables
JavaScript
Switch branches/tags
Nothing to show
Permalink
Failed to load latest commit information.
test Renamed to deepequal Jan 23, 2014
.gitattributes initial commit Jan 22, 2014
.gitignore initial commit Jan 22, 2014
.travis.yml add .travis Jan 30, 2014
History.md add project documents Jan 27, 2014
License.md add project documents Jan 27, 2014
Makefile initial commit Jan 22, 2014
Readme.md add travis build image to Readme.md Jan 31, 2014
index.js Renamed to deepequal Jan 23, 2014
package.json 0.0.1 Jan 27, 2014

Readme.md

deepequal Build Status

Deep comparison of two variables

Unlike deep-equal, this will also compare Buffers, Regular Expressions, and NaN (which I believe should equal NaN).

var deepEqual = require('deepequal');

deepEqual([1, 2, 3], new Array(1, 2, 3));
// true;

deepEqual(NaN, NaN);
// true;

deepEqual({ a: [1, 2, 3] }, { a: [1, 3, 2] });
// false;

Installation

$ npm install deepequal

Dependencies

API

deepEqual(a, b, strict)

  • strict - Use strict comparison (===) between primitives (Boolean, String, Number) (default: false)