Doesn't compare Sets
See original GitHub issueHi!
I just noticed this library does not compare Sets correctly.
Repro:
var dequal = require("dequal")
let a = new Set([1,2,3,4])
let b = new Set([1,2,3,4])
console.log(dequal(a,b))
https://runkit.com/embed/yiu9lr2kont0
As an example, lodash’s isEqual
does compare Sets and in the above use case does
return true.
This is also related to https://github.com/kentcdodds/use-deep-compare-effect/issues/15
Fran
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
How to efficiently compare two unordered lists (not sets)?
O(n): The Counter() method is best (if your objects are hashable): def compare(s, t): return Counter(s) == Counter(t).
Read more >Ultimate Guide - Compare two lists or datasets in Excel
Learn how you can compare two lists, two columns or two data sets in Excel. We will look at conditional formatting, formulas and...
Read more >The Best Ways to Compare Two Lists in Python
The easiest way to compare two lists for equality is to use the == operator. This comparison method works well for simple cases,...
Read more >4 Must-Know Methods for Python Set Comparison
In this article, we will go over 4 must-know methods for comparing sets. Let's start with creating a set object. myset = {1,...
Read more >Don't Get Blindsided by PROC COMPARE - SAS Support
The COMPARE procedure simply compares the data sets based on the variables in common and reports its findings based on that comparison. If...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It’s not released yet. I’ll push to have both dequal & klona 2.0 done this week – they go hand in hand.
Great, thank you @lukeed !