Fork me on GitHub
#re-frame
<
2018-12-07
>
Whiskas12:12:59

Hey guys, what is the proper way to use JSX components with re-frame/reagent ?

ouvasam16:12:22

Hi, I use component like react-virtualized, react-pose, etc... Is it component like this where you want help ? (not sure to understand what you search, sorry)

manutter5113:12:43

Or hmm, that’s going the wrong way, reagent->jsx

macrobartfast16:12:37

when you're developing a full stack app (ring backend api and a re-frame front-end in my case with cider interactivity on both) how do you structure your project directories during development so the re-frame app can be served by the backend locally? side by side with symlinks or something? re-frame inside of the backend directories? something else?

macrobartfast16:12:46

I suppose it depends on what the final production arrangement will be, for which I could also use some idiomatic suggestions. I'm guessing folks may have other options than serving a re-frame site from resources/public on a compojure back-end.

macrobartfast16:12:13

I think I'm going to have other things hitting my backend API (a react native mobile client, for example) if that's a factor.

manuel17:12:13

I simply use two directories: clj and cljs. Server side code and client side code, respectively. Client side follows re-frame guidelines, so events, views and subs namespaces grouped by areas in the app (topics, if you will). Server side is divided into model, apis, services, and utils usually.

manuel17:12:41

And then I have a template.clj which is the index.html served via ring to the browser.

mccraigmccraig17:12:13

in our case the general division of code is similar to @manuel 's, but we use a monorepo with modules for the high-level divisions (async, db, model, api, streaming, app-core, main-app, onboarding-app) and we have a fair bit of code-sharing between front and back-end, so lots of things are .cljc and we don't have any clj/`cljs` directories, just src and testin each module

macrobartfast18:12:35

that's helpful... and I also just remembered polylith as something I might think about, which almost sounds a bit like what @mccraigmccraig is doing.

mccraigmccraig19:12:36

it seems quite similar - we tend to use lein :source-paths (each module has its own project.clj) instead of symlinks, but to the same effect - dependency sources get drawn into the same classpath and can be recompiled / reloaded just like it was a single module

escherize19:12:29

Do people still use re-frisk? What's the preffered event visualization tool? 10x?

manutter5119:12:49

I use re-frisk and 10x together -- I like the re-frisk view of the app-db better, but 10x has all that other cool stuff. So far no problems having them both on at the same time.

👍 1
mikerod20:12:58

Yeah, I still use re-frisk for looking at the app-db as an expandable tree

mikerod20:12:06

haven’t tried 10x to do that instead