what was thompson working with when he discovered the cathode rays
Thomas discovered cathode rays when he was working with electrons. He was performing experiments with electrons when one of them became electrically charged and a beam of light came from it, this creating a cathode ray.
In 1897 British physicist J.J. Thomson showed the rays were composed of a previously unknown negatively charged particle, which was later named the electron.