meander

All things about https://github.com/noprompt/meander Need help and no one responded? Feel free to ping @U5K8NTHEZ
noprompt 2021-04-09T15:57:59.105800Z

$* is supposed to this kinda thing but I just looked at it and noticed it wasn’t working.

noprompt 2021-04-09T15:58:12.106100Z

Which is annoying because I thought there were tests for it.

noprompt 2021-04-09T15:58:36.106500Z

I’ll fix that and then make a new release today.

👍 1
2021-04-09T22:28:57.107300Z

Is it possible to add a key to a map only if the value assigned to it is other than nil?

2021-04-09T22:30:26.107600Z

simple stupid example

(m/rewrite {:a 1 :b 2}
  {:a ?a :b ?b :c ?c}
  {:a ?a :b ?b :c (if-not-nil ?c)})
;; => {:a 1, :b 2}

2021-04-09T22:32:02.108Z

I actually found this, but maybe there is an easier way?

(m/rewrite {:a 1 :b 2}
  {:a ?a :b ?b :c ?c}
  {:a ?a :b ?b & ~(when ?c [[:c ?c]])})