A chemical reaction controlled by light-activated molecular switches based on hetero-cyclopentanediyls