Operando two-terminal devices inside a transmission electron microscope