Fork me on GitHub
#fulcro
<
2020-07-10
>
zilti08:07:07

Okay, this confuses me now. That :initial-state in ActivityFeed was something I didn't really look at anymore because I thought whatever's there is ignored except for when the component is being routed to. Instead of being used as a component inside another component.

zilti08:07:24

So I didn't expect putting a vector there would solve it. Wow.

tony.kay15:07:47

really, my 2 second glance on Query/ident/initial state fixed your problem? Take that to heart šŸ˜‰

tony.kay15:07:02

query/ident/initial state, and state over time. Those are the keys.

tony.kay16:07:29

and initial state has nothing to do with routing (directlyā€¦it could be leveraged there, but isnā€™t): Think of Fulcro as a library that lets you make animations over time via a data structure. Every frame of that animation is a snapshot of state. I personally imagine those cells Disney used to draw on, but Iā€™m old šŸ˜›. All of those cells but one is a small delta from the prior one. :initial-state is the first cell in the sequence, and the deltas are generated via mutations (loads are just a conveniently-written mutation that modifies your state by pulling stuff from some remote data source).

šŸ˜† 6
tony.kay16:07:19

You could think of the state database as a textual description of a view, and the UI code as the ā€œartists renditionā€ of that view. Thus, the state database over time is like a ā€œbookā€, and the UI is the (unusually true to plot) ā€œmovieā€