Fork me on GitHub

@escherize Sorry I didn't word it right. I didn't really know how actually react works. For example, if I have a component:

(defc b
  [:h1 message])

(defc a
  [:div (b "foobar")])
I can say for sure (b "foobar") inside a will point to previous state of the b after the first rendering. But what if a is declared using defn instead of defc. Will it create a totally new react component for b each time a re-render? Because I want to wrap my component with multimethod.
(defmulti my-component :id)

(defmethod my-component :table/user
  (c option))

(defmethod my-component :table/role
  (d option))
There's a "gotcha" in reagent regarding multimethod: So I'm wondering is that "wonky" things regarding multimethod also exists in rum.

Petrus Theron09:04:02

Rum performance: does Rum always re-run every function and defer to React for DOM blitting when a change is detected? What are my optimization paths when I encounter too-frequent updates on a subdividable tree? Specifically, I'm passing in a DataScript db, which changes frequently, but the queries affecting a given view don't change as frequently. Is the solution to have dumb vs. smart views that run efficient change queries and only trigger updates downstream if those query results differ?


yep, that’s usually the easiest way to cut re-rendering of a sub tree


In other words, use :rum/static downstream right?