Fork me on GitHub

what is the best practice for swapping / integrating a subview inside a other one? Should I put the entire thing into state and just let my root-view take whatever is under :view and display that? Or should I do something like (if (:show-detail state) ...)


or in general dynamic component composing


Yup, I do it more or less like re-frame as well. It works okay so far.


@dvcrn: my preference is to only ever put plain data into the ratoms. Then the renders make their decision based on that data -- when deciding which sub-render should be used. I don't like the idea of putting references to renderers into a ratom ... just simple data (apart from anything else this makes it easier to use figwheel because you won't want a r/atom holding a reference to your OLD renderer, when figwheel was loaded a new one).


yeah that makes sense. That's also why I asked initially simple_smile


@gadfly361: what library you’re using in [h/fake-content] (what is the h namespace), please?


and also soda-ash seems pretty nice to me, thanks


@pepe [h/fake-content] is just a lorem ipsum paragraph. The "h" is what i aliased this helpers namespace:


@gadfly361: ok, I thought some library like Faker in Ruby 😉, thanks


Thanks for mentioning! I should probably clarify in the docs, i can see how that comes outa nowhere now.


@gadfly361: hey, I’m really enjoying soda-ash. I was wondering how you would recommend approaching the more complex semanticui stuff involving their proprietary scripts (like this neat github search or their validation? Is it outside the scope of the library?


@sooheon: glad you're enjoying it! I haven't yet given it much thought. I'm going to try and cover most of the class related stuff first, and then circle back to think about a more 'reagenty' way to do some of the javascript bits. As an aside, I am happy for help/suggestions on how to best go about that.


gadfly361: Ah I see. I have no real good ideas for that either, but it’d be pretty great to have a simple way to use all of that extra functionality.


@sooheon: if you scroll up a bit there was some discussion about using semantic-ui components, like the dropdown for example.


Not sure if things like validation make as much sense in Clojurescript/React though if you can just hook bouncer/validateur/schema/whatever.


jaen: thanks! will check it out. For validation, I am using the cljs libs you mentioned for the logic, but I was thinking it’d be nice to have a reference front-end implementation that works just like [this](;last-name=#updated-form-validation) for example.


@jaen @sooheon dropdown snippet above is a great reference!


@sooheon: yeah, it would probably be nice to have something like that, but I guess it's more of a job for a React form library if anything. I'm not even 100% sure if React would take kindly to jQuery mucking in it's divs.


I think I had some sort of a mini-library to that effect, but never polished it enough to consider OSing it.


But I guess at least reagent form libraries must have something like that.


@gadfly361: well, it's nothing one couldn't construct with re-frame's tutorial on stateful components and semantic-ui's example, but thanks nonetheless.


<3 re-frame docs


Yeah. Even in that case you already figured some of what they describe, they are still great review material.