Fork me on GitHub
#fulcro
<
2020-09-08
>
jaide02:09:11

What’s involved in adding various elements from the RAD demo to the official fulcro 3 template?

tony.kay14:09:26

ummm. coding? Really you just add the deps and start using it. Not sure what you’re asking.

tony.kay15:09:55

you do need to upgrade the version of Fulcro, since the RAD tools use some of the newer features. I think it requires the multi-root renderer, which is documented, I believe.

jaide16:09:20

Hah, I suppose after a night of sleep that was not a very good question. Sorry about that! I just got the Fulcro 3 template working with migratus and replaced the mock database with postgres. I'm watching your overview vid and reading up on the rad book so I'm trying to decide if I should start over again with the RAD demo, or if I should pull in RAD components as needed, or just stick to Fulcro 3 to get it working then migrate later.

jaide16:09:30

As for a first question: Is Datomic required for RAD?

Michael W16:09:02

It’s not required but the sql adapter is alpha and unmaintained.

jaide16:09:29

I can't tell yet if you can just use Postgres, if you use Datomic on top of postgres, or if Datomic is a hard requirement.

Michael W16:09:37

You can write resolvers into any database you want, the datomic support just makes it so you don’t have to do that for datomic.

Michael W16:09:26

Datomic Pro can run using postgresql as it’s storage back end.

jaide16:09:51

Hmm ok so not using datomic is possible, but its not a widely-supported, polished path yet. Last I saw, Datomic was not open-source and I would need to pay to use it?

jaide16:09:19

Does RAD work best with Datomic Cloud (or at least dev-local version to get started) or the Community Edition? I find myself a bit overwhelmed with the options atm 😅

Michael W16:09:58

If it’s not commercial you can use datomic free. If it’s commercial you do have to pay.

Michael W16:09:23

Datomic cloud support is new, I saw an announcement about it recently that it is supported now.

jaide16:09:48

Haven't thought too far ahead on that yet. Aiming to keep it open-source but perhaps charge a few bucks a month for a hosted service version of it. But only if it comes out well, people find it interesting\useful, and it's a reasonable amount of work to add in paid subscriptions. That likely would put me in the commercial territory. Which means I should probably use the Starter on-premise to get started or the Datomic Cloud dev-local.

jaide16:09:49

I definitely lack sys-admin skill\experience so I'm probably much better off with datomic cloud. I'll start with dev-local, keep it open-source until I'm ready to create a paid version then use a paid Datomic Cloud setup for production sometime down the road.

jaide16:09:29

Now I'm kinda thinking it might be best to keep with the fulcro3 template + postgres config. Get to a stable place with a CLI or TUI then try implementing it with RAD using Datomic Cloud for comparison.

Michael W17:09:25

You can use RAD with postgres you just have to write resolvers, pretty much the same you would do with just plain fulcro.

Michael W17:09:01

RAD gives you quite a bit of things, but for me forms is the killer feature, not having to write every piece of html is very nice.

jaide17:09:39

Oh! That doesn't sound so bad. For someone who hasn't developed with Fulcro yet or RAD, you would recommend getting started with RAD?

Michael W17:09:01

Yes, it does a lot for you that you would otherwise have to do manually.

Michael W17:09:10

The rad demo repo shows off some cool stuff, clone it, fire it up, and see all the stuff you can do.

jaide17:09:29

Good idea! Thank you.

Michael W17:09:30

It uses an in-memory datomic free so you don’t have to do anything at all.

jaide17:09:45

I'm not married to Postgres, just considering using what I'm familiar with to get something done vs learning an entirely new stack. Datomic has always sounded appealing to me.

Tyler Nisonoff17:09:35

Theres also this branch of the demo: https://github.com/fulcrologic/fulcro-rad-demo/tree/datomic-cloud which runs the demo on dev-local / Datomic Cloud

jaide17:09:38

Awesome thanks for the link!

Michael W17:09:05

I am using datomic-free for now, if I go commercial I’d probably use datomic pro on top of postgres citus.

tony.kay18:09:09

The overall design of RAD, as expressed in the book, is database agnostic. It’s attribute-centric. A database adapter is actually a very thin layer, and hand-writing resolvers is quite tractable…it’s what you’d do with non-RAD Fulcro anyway, so you’re definitely not losing anything, right? What you gain is your data model expressed in a central open-map place where you can hang any addl info you want to say about that data, which then lets you use the data management layer, rendering, etc.

jaide19:09:04

Alright! May as well go for it and figure it out 🙂

roklenarcic20:09:19

Hm I tried using ::attr/computed-value attribute in my report and it just shows up empty…

AJ Snow23:09:42

from what work I've done so far, in fulcro components are designed around data flow, not the aesthetics of a component (css, html structure, etc). is that right?

tony.kay23:09:24

css/html and such are just function calls and artifacts…the proper components are those things that have real data needs

👍 3
tony.kay23:09:32

often the two align