21 Commits

Author SHA1 Message Date
Ryan Roemer
7079a22cc2
Bugfix: support Object.create(null) (#123)
- Allow use of `Object.create(null)` to work without error. Fixes #64 
- Add customized tests.
2023-03-16 08:34:11 -07:00
Kylie Stewart
d0a0b5add8
Add Preact support (#76)
Co-authored-by: David Dios <dios.david@thedevcore.net>
Co-authored-by: Ryan Roemer <ryan.roemer@formidable.com>
2020-05-08 16:43:09 -06:00
Kylie Stewart
ad48a7ca78
Extend hasArrayBuffer check to support older IE 11 versions (#71) 2020-04-30 18:33:47 -06:00
Chris Bolin
1210a90b69
rename exportedEqual to isEqual (#59) 2020-02-05 11:42:07 -07:00
Ryan Roemer
84dc76fd76
Chore: Optimizations (#57)
* Some micro-ops index.js

* Update modification notes

* Get rid of strict

* Update numbers

* Update changelog

* ignore VS Code config

Co-authored-by: Chris Bolin, Phil Plückthun
2020-02-04 23:04:39 -07:00
Ryan Roemer
5d71c91e73
Feature: Add support for ES.next Set, Map, ArrayBuffer (#51)
- Update library to include ES.next support for `Map`, `Set`, `ArrayBuffer`. Part of #36
- Update to `fast-deep-equal@3.1.1` with modified support for ES.next data types.
- Upgrade lots of `devDependenices`
- Use `fast-deep-equal` tests directly in our correctness tests.
- Update CI to modern Node.js versions.
- **Note**: There's a bug / limitation of `Set` comparisons whereby objects are compared by reference not value. Tracked at #50 . In our `yarn benchmark`, `lodash.isEqual` gets test differences because it correctly handles those.
2020-01-29 13:52:55 -07:00
Va Da
294d6e0080 Optimizations (#41)
* perf: ️ remove redundant instanceof Element check

On the next line tripple equals === should ensure b is instance of
Element.

* perf: ️ remove redundant a === b expression

The very first line of the function already checks `if (a === b) return
true;`, so at this point we know for sure that a !== b
2019-02-18 12:01:23 -07:00
Chris Bolin
c0c1177afe
fix react-native bug for DOM "Element" checking (#39)
* fix react-native bug for DOM "Element" checking; ensure Internet Explorer still works
2018-11-09 10:39:43 -07:00
Chris Bolin
238b3cfde1
simplify DOM element handling and testing (#37) 2018-11-08 14:54:30 -07:00
viper1104
f26b6c52ba Comparing DOM elements (#33) 2018-11-08 08:54:41 -07:00
Nicolau Gonçalves
321cb1e1cf Fix for localized versions of IE11 (#28) 2018-08-14 22:06:05 -06:00
Chen Ye
8033b32c61 fix check to work in prod (#26) 2018-06-25 11:24:00 -06:00
Samuel Estrella
8122fedecc
Feature/fast deep equal@2.0.1 (#21)
Up to date with fast-deep-equal@2.0.1.

* null and object comparison
* new behavior: different functions that are not equal
* new behavior: handle NaN
* Add tests from fast-deep-equal@2.0.1
* Move tests from fast-deep-equal@2.0.1 to separate file
* Add comments to identify fast-deep-equal code
* Add comments to identify custom handling for React
2018-06-04 13:48:02 -07:00
Chris Bolin
b0b188e664
1.0.0 RC (#6)
* react-fast-compare README

* react-fast-compare package.json

* clear out bad fast-deep-equal references

* deeply test react elements, just not the _owner field; update tests
2018-04-12 17:33:57 -06:00
Chris Bolin
aef8b0ce4d
Handle React Elements and Circular References (#2)
* don't recursively traverse react elements with owners. warn (not crash) on recursive calls. ensure error.message exists
2018-04-10 22:41:28 -06:00
Evgeny Poberezkin
c8786d265d check number of keys first 2018-02-25 20:30:58 +00:00
Vadim Dalecky
d3b4868326 feat: move key length check before deep comparison 2018-02-25 18:46:34 +00:00
Vadim Dalecky
60cfd3c635 feat: move time check next to instanceof Date 2018-02-11 21:49:52 +00:00
Vadim Dalecky
7d1f4ea546 refactor: address PR comments 2018-02-11 14:41:37 +00:00
Vadim Dalecky
a127d3ff0d chore: prepare PR 2018-02-11 10:30:08 +00:00
Evgeny Poberezkin
e80419b8d8 feat: "deep equal" with tests 2017-06-16 22:33:44 +01:00