I have a use-case where I often need to compare 2 hashes where I don't care about the values of particular keys. For example ones which contain timestamps, or the following example which contain a 'duration' key (representing milliseconds):
The logic would be the same as above, i.e. ignored keys would have to be at the end of each path. My guess is this may be a common enough use-case that a shorthand option like this would be valuable to users.
I might have a stab at a PR if you like the idea. Awesome library btw.
I have a use-case where I often need to compare 2 hashes where I don't care about the values of particular keys. For example ones which contain timestamps, or the following example which contain a 'duration' key (representing milliseconds):
I can ignore differences in the 'duration' values with a block:
But I'd love to be able to write something like this, where :ignore_keys can take a single value or array of keys to ignore:
The logic would be the same as above, i.e. ignored keys would have to be at the end of each path. My guess is this may be a common enough use-case that a shorthand option like this would be valuable to users.
I might have a stab at a PR if you like the idea. Awesome library btw.