JSPM

object-equal

1.0.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 20
  • Score
    100M100P100Q45626F
  • License MIT

tests wether two objects are equal (shallow).

Package Exports

  • object-equal

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (object-equal) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

object-equal

simple function that tests, if two objects are equal (shallow).

install

npm install object-equal

usage

var assert = require('assert');
var equals = require('object-equal');

assert(equals({a:1, b:'nada'}, {b:'nada', a:1}));
assert(!equals({a:1, b:'nada'}, {b:'nada', a:2}));
assert(!equals({a:1, b:''}, {b:'nada', a:1}));
assert(!equals({a:1, b:'nada'}, {a:1}));
assert(!equals({a:1}, {a:1, b:'nada'}));

test

npm test

license

MIT