Fork me on GitHub

I have reagent/atom with a vector of maps. The atom is populated viajson/transit, websocket::onMessage using reset! each time, I create an html table with the atom. The table updates when I add to the vector but it does not work if I update a map in the vector. In fact, even when I add to the vector, the table cells only update if I refresh the page.


Need a minimal reproducible example.


Thanks. While making an example I found my issue. Creating a table from a vec of maps works just like like it should. My issue is a bug in the code I wrote. My table cells are input boxes and those need some work then thing should be better. thanks again!e

👍 3

I have a sort of general component design question. I'm thinking about writing a color picker - how would you typically return the chosen values? The obvious answers to me seem to be either pass a cursor to the component, or you provide it with some callbacks. I've mostly gone with something like cursors before, but if I want things to "happen" (like sending data to a server), would you just go with callbacks?


My starting position would be callbacks. Just see how that turns out for you, and if you need, you can move to more interesting mechanisms for accessing state.