In situ monitoring of optical and structural switching in epitaxial YHx switchable mirrors