The first televisions used something called a Nipkow disc to generate an image. It was perforated with tiny holes in a spiral pattern. As the disc spun, a flashing neon light would vary between light and dark. Thus producing an image. Each hole produced one scan line. Images were rendered vertically instead of horizontal. Images they produced were about the size of a postage stamp and needed a magnifier to see. Vertical resolution was very good for the time, but horizontal was quite limited. Early sets had between 30 to 48 lines. The technology topped out at 240 lines shortly before WWII. The BBC opted for 405-line electronic television instead.
The camera worked on similar technology. A nipkow disc was placed in front of an arc lamp. The subject had to be brightly lit while the studio had to be in near darkness. The light would "scan" the subject and reflect back to a bank of photocells. Of course this limited early television production to studio work. It couldn't be used reliably outdoors. In the mid-1930s, Baird did develop a work around by shooting the production on film, then scanning it. Which became the common method for producing pre-recorded TV series up until very recently.
Prior to the 1930s, CRTs were mostly a curiosity. The effect was noted at the turn of the century. The electronic television was invented by Kenjiro Takayanagi in 1926. This used a nipkow disc camera with a CRT display. Philo T Farnsworth invented the all electronic television and camera system a year later.
Interstingly, Farnsworth didn't really care for his invention once it became popularized, considering it a vapid form of entertainment.