3 ms·
It's a pity that you can't implement a function in an object to consider it equal to another object with the same member values.
by philipwhiuk 2y ago
It's a pity that you can't implement a function in an object to consider it equal to another object with the same member values.
- tobz1000 2y agoThere is a years-old proposal for deeply-comparable types: https://github.com/tc39/proposal-record-tuple https://github.com/tc39/proposal-record-tuple Maybe we'll see it one day.
- afiori 2y agoI highly doubt this will go anywhere, it is much more likely to get some custom equality in data structures. For example I would like a Map<array, any> that compare keys by shallow equality, so to behave like multidimensional tables