Fork me on GitHub
#reagent
<
2015-12-17
>
snowell17:12:59

So there’s a macro on this wiki page (https://github.com/reagent-project/reagent/wiki/Beware-Event-Handlers-Returning-False) for dealing with a certain React warning

snowell17:12:12

(defmacro handler-fn
  ([& body]
    `(fn [~'event] [email protected] nil)))  ; always return nil

snowell17:12:02

When trying to use this, it seemed like it never compiled, and that the syntax is a little wonky. I was able to fix it by taking out the parens after handler-fn:

(defmacro handler-fn
  [& body]
    `(fn [~'event] [email protected] nil))  ; always return nil

snowell17:12:19

Is this an error in the page, my compiler, my usage, or what?

jaen17:12:54

Interesting; they should be equivalent I think.

snowell17:12:29

Hm. Perhaps something was just up with my figwheel or the order I was trying to compile/run things