Hello!
With cljs 1.12.42:
cljs.user=> (max "x" "y")
"y"
cljs.user=>
With cljs 1.12.134:
cljs.user=> (max "x" "y")
"x"
cljs.user=>
Probably related to CLJS-3425 and this commit which added NaN checks:
(defn ^number max
"Returns the greatest of the nums."
([x] x)
([x y]
(cond
(NaN? x) x
(NaN? y) y
(> x y) x
:else y))
([x y & more]
(reduce max (cljs.core/max x y) more)))
But:
cljs.user=> (NaN? "x")
true
cljs.user=>
Hence the result.
Not sure what the expected result should be since min/max are only supposed to work with numbers but current behavior is surprising.
See also: https://github.com/jank-lang/clojure-test-suite/pull/839.