Fork me on GitHub
#re-frame
<
2017-04-06
>
curlyfry10:04:37

@danielgrosse I usually have the view/event/subs/db structure per route, or by component if the component is reusable/relatively self-contained

danielgrosse11:04:26

@curlyfry On the other side, it would promote a single db for an component which IMO goes against the one db solution of re-frame

curlyfry11:04:34

@danielgrosse I'm not sure if I understand, you would still use the global app-db

curlyfry11:04:01

The db namespaces I usually set up a particular part of the app-db, as well as the specs for that part

curlyfry11:04:28

and in the top db, I import it into the global default db + spec

curlyfry11:04:03

You could do all of that stuff in the same namespace (the top db one), but I find it gets pretty huge for bigger apps

danielgrosse11:04:42

So you use a db in the different parts but concat them into the main db at initialization?

curlyfry12:04:09

@danielgrosse Yup! Try having it all in the main db namespace first, and then refactor out as needed when it gets big 🙂

jfntn23:04:10

Has anyone been working on this issue since it was closed? https://github.com/Day8/re-frame/issues/210