A rough account of what I did with Emacs recently.
In general, the Virtual Dom concept pioneered by React.js has proven itself in many production environments, and it has shown that you can in fact model GUI components as immutable data structures. With a Virtual Dom, your code would indeed throw away the old immutable virtual window object and create a whole new immutable virtual window object, but the framework would do the grunt work of making sure only the bits of the real window that differ are actually changed! That way your code works largely with immutable copies of the window (which are less prone to bugs involving accidental/hard-to-track-down mutation) while the user would see and interact with a single, long-lived, smoothly-updated entity: the best of both worlds.Unless I'm mistaken, that's pretty much how the curses library works, and that predates React by a long way... (Wikipedia doesn't give an exact date, but Rogue, based on curses, showed up about 1980 apparently.)
previous month | current month| next month