@Christoph-Hart I was originally approaching the Globals container like a React state. This was way back when I started this project and I just continued with that paradigm without realizing how HISE restores its state. However, I totally see the danger here. I'll need to refactor it all.
On another note, I'm trying to understand the optimization of the const var. If I store a bunch of UI elements in one const var thisNamespaceUI = {} for clarity, do I get the same compile optimizations as if I were just storing them in individual constant variables? For example, you'd have thisNamespaceUI.panelOne.buttonOne thisNamespaceUI.panelOne.buttonTwo etc.