Fork me on GitHub
#reagent
<
2018-01-10
>
lilactown00:01:26

K, so reagent 0.6.2 does not work (I get a different error message that prevents me from building at all). reagent 0.8.0-alpha2 shows the above broken behavior

lilactown00:01:41

0.7.0 works as expected:

cljs.user> (reagent.dom.server/render-to-string [:div "hello"])
"<div data-reactroot=\"\" data-reactid=\"1\" data-react-checksum=\"-857140882\">hello</div>"

lilactown01:01:42

:face_with_rolling_eyes: it worked in my project started with figwheel-node template, but it’s not working in my project started with the serverless-cljs template

eveko16:01:58

is there a way to pass a string to alter the hiccup structure? That way I can change the icon from semantic ui (defn icon-div [identifier] [:div.identifier.icon])

gadfly36116:01:58

[:div {:class xxx}]

benny16:01:50

does anyone here have suggestions on how to go about doing tdd with reagent? i'd prefer to have tests but have never done it with react let alone reagent

shaun-mahood17:01:29

@benny: Have you tried devcards? You can define tests and much more. https://github.com/bhauman/devcards

benny17:01:12

intriguing but that doesn't look like it would allow me to write actual tests against components and use it in CI to guard incremental features

benny17:01:36

oh nevermind, i went deeper and it looks like it does way more like you said

benny17:01:45

that's awesome, thanks @shaun-mahood

mikerod23:01:27

@yogthos first I’ve seen that. Intriguing

mikerod23:01:15

I guess there is no proprietary concerns with replicating the React API

mikerod23:01:26

(I think there were several of these already)

yogthos23:01:16

yeah the fact that it's a drop in replacement makes it interesting

yogthos23:01:30

and looks like it's actually being used in production

mikerod23:01:11

Yeah, it looks pretty official

mikerod23:01:22

I’d like to look into some of its claims on performance as well

yogthos23:01:19

yeah the benchmarks here https://nerv.aotu.io/ seem too good to be true 🙂

yogthos23:01:48

I'd really be curious to know how it's so much smaller than react while also having better performance

yogthos23:01:59

there have to be some trade-offs here presumably