Fork me on GitHub
#reagent
<
2018-05-01
>
juhoteperi11:05:08

Could someone take a look at these :class changes which fix some problems introduced with 0.8 :class collection support: https://github.com/reagent-project/reagent/pull/368

juhoteperi11:05:11

The potentially breaking part is that name is called for every :class value, which will fail for some types (like boolean or numbers).

lwhorton15:05:31

just my two cents, but I didn’t even know we could use keywords as class names, and I would prefer to have collection support over keyword -> string support

👍 8
juhoteperi15:05:01

Keywords (and symbols) have worked always, collection change broke it in one case (when used together with element name shorthand)

pmooser20:05:48

I'm trying to update to reagent 0.8.0, but I'm seeing an error of "Uncaught Error: js/React is missing" when calling reagent.core/dom-node. Anyone have any pointers what might cause this? If I type "React" in the js console, there is an object there.

pmooser21:05:44

Ok, totally deleting cljs output dir and recompiling seems to have addressed that issue. I think.

pmooser21:05:24

Now that reagent depends on react 16 by default, is there a way we can hook into the lifecycle method: getSnapshotBeforeUpdate ?

pmooser21:05:30

It actually seems to work, with some scary warnings that it won't be calling the unsafe lifecycle methods that it claims reagent still uses.

pmooser22:05:16

I can't figure out how to convert the arguments to getSnapshotBeforeUpdate into something useful from the reagent side, though.

pmooser22:05:33

Like, for example, something that I could pass to r/dom-node.

pmooser22:05:46

Anyone have any insight into that?