Dear Observable team,
I have one svg divided equally by 9 square cells. Each cell draws exactly the same stuff based on a single graph data structure. They differ only in a dependency to its own start (x, y) position. Is it able to create a cell template so the change made in one cell can reflect on all cells?
As there is no way to create a cell template, instead of creating and updating each of 9 cells manually, i created a nodeGroup (to initialise visual) and a nodeGroupObserver (to update visual on drag) cells which declares only one visual stuff. I made it depend on “initCellCloneConfig” and “updateCellCloneConfig”, respectively. Whenever there is a drag event the config generates iterable promises.
Example: https://observablehq.com/d/66a62a5cbbf0ac2c
Thanks for your time