StefanoLanzavecchia wrote: But if this is the case, I guess you'd be better off sending the data along with the method invocation that causes the refresh of the GUI.
This is kind of what I'm doing right now - in the beginnings of what maybe a light-weight framework. In response to a fetch (POST) from the browser, triggered by an onClick on some element, say, I return a JSON array of one or more id and innerHTML pairs that is then set by the browser. I assume I could enhance this to have a particular update function called as well. I'm wondering how far one can get with such a simple framework.