Fork me on GitHub
#reagent
<
2018-06-25
>
arlicle09:06:42

hao can i render recursive at reagent ?

curlyfry10:06:03

@arlicle Can you elaborate or provide an example of what you want to do?

arlicle10:06:27

@curlyfry my data just have tow level, but it show errors :Uncaught RangeError: Maximum call stack size exceeded

arlicle10:06:38

I use boot-cljs and reagent

Jon10:06:12

what's your data and try some logs//

arlicle10:06:08

I find the error đŸ™‚ thank you @jiyinyiyong

troglotit11:06:16

Hey! I tried {:style {:display :flex}} instead of {:style {:display "flex"}} and to my surprise - it worked! Is there a part of documentation where it is described?

pesterhazy16:06:32

it's essentially like clj->js right?

juhoteperi16:06:35

@pesterhazy Yes, with additional transformations like snake-case to camelCase for maps and named (symbols and keywords) to strings

juhoteperi16:06:41

Hmm, the ifn? case is interesting, I think that the additional fn is unnecessary for real functions (as they are already JS functions), but could be required for some ifn

juhoteperi16:06:34

If I had proper performance tests I'd also consider rewriting this into protocol as that should be faster than cond

bherrmann16:06:59

FYI: I saw this on redit… https://learnreagent.com/

juhoteperi16:06:46

@bherrmann I'll share coupon/affiliate link here and on Reagent readme when it launches đŸ™‚

bherrmann16:06:22

Cool, I only glanced it over, but it looked interesting to me - and nicely done

pesterhazy17:06:59

@juhoteperi good point about the protocol

pesterhazy17:06:26

I didn't know that reagent wrapped each function in another anon fn

pesterhazy17:06:17

maybe that's necessary for partials and things like that