Cache main node of apps so state is preserved when navigating away