fast-equals
Advanced tools
Changelog
4.0.0
In previous versions, there were automatic fallbacks for certain ES2015 features if they did not exist:
Due to the omnipresence of support in both browser and NodeJS, these have been deprecated. There is still an option if you require support for these legacy environments, however; see createCustomEqual
and createCustomCircularEqual
for more details.
createCustomEqual
contract has changedTo allow more flexibility and customizability for a variety of edge cases, createCustomEqual
now allows override of specific type value comparisons in addition to the general comparator it did prior. See the documentation for more details.
createCustomCircularEqual
addedLike createCustomEqual
, it will create a custom equality comparator, with the exception that it will handle circular references. See the documentation for more details.
Prior to 4.x.x.
, instanceof
was used internally for checking of object classes, which only worked when comparing objects from the same Realm. This has changed to instead use an object's StringTag, which is not realm-specific.
For better typing in edge-case scenarios like custom comparators with meta
values, typings have been refactored for accuracy and better narrow flow-through.