Fork me on GitHub

anyone know of a good example of a “large application” built with re-frame? I know about the relevant wiki section


@miguelb: i've got a 40kloc app, with about ~18kloc in re-frame/cljs ... dunno if that counts as large !


Working with a re-frame app right now and I was looking for examples on how others have structured their large apps


i've tried a few different things - the approach which is sticking is to divide the app into components and areas, and give each of those things its own [subs / handlers / views] namespaces, carving those namespaces up themselves when they become unwieldy, so e.g. having app.components.infinite-scroll.subs app.components.infinite-scroll.handlers app.components.infinite-scroll.views namespaces


do you also split up the db ?


i haven't done that - though i have split out the schema definitions into the components


do you have situations where a view in a one “component” namespace must dispatch an event in another namespace? (for example in app.components.widget_a.view dispatches :widget_b/something) If you do, does widget_b handler’s ns have the handler?


ah, sometimes i have the notion of an empty component and functions to create those structures for app-db are also split out, so i guess my app-db is a little split, though not greatly


yeah, it's not uncommon for one area to dispatch an event handled by another area. it hasn't happened often enough for me to have formalised it yet though


sounds good, thanks for the information


I’m sure i’ll have more questions!