Is there an equivalent to select-keys? I'm currently trying to translate some of my vanilla clojure code to using specter (great library by the way, I use it in almost all my projects), and trying to navigate to a view of all the values in a map where the key for it is contained in some collection seems to me to be a not-uncommon usecase. I've tried a couple of solutions for it, from using (apply multi-path (map keypath coll))
to (filterer (comp set-name first))
and no matter what I do, the performance is always at least twice as poor as just calling select-keys
. I've been perusing the docs, but nothing is jumping out at me.
I see that submap
is what I was looking for
submap
has much more acceptable performance, being only slightly slower than the select-keys
implementation. Again, thanks for the library!