Classic mains transformers were once an essential part of any radio or television receiver. Large, heavy - a "necessary evil" - provided the right filament voltage for the lamps, anode voltages and transistors’ supply voltage. In addition, they provided impedance matching of output stages of tube amplifiers or those based on germanium transistors (high circuit impedance and low of a speaker). Their advantage was high resistance to momentary voltage surges or overload, galvanic isolation of circuits and low price in relation to semiconductor prices. Disadvantage: inflexibility (fixed gear, number of taps determined in the production process).
The situation began to change in the seventies: cheap and efficient semiconductors replaced transformers in most applications. Silicon transistors work with higher currents and voltages when compared to germanium, thus it is much easier to maintain required impedance matching or switching frequency. Switching power supplies began to dominate in power systems and they rule supreme up to this day, even in small smartphone chargers. And do you remember the first Nokia 3210 charger (based on a transformer)?
Transformers are still readily used in systems such as central heating controllers, where simplicity and reliability of operation are important - as are EMC compatibility issues (impulse technology has problems with them). Vacuum encapsulated transformers are particularly popular as they are more resistant to vibrations and impacts. On request, it is possible to incorporate a simple short-circuit protection. What's more: it is possible to make a transformer with any voltage ratio and the number of taps. There are also "green" products marked ErP P0 <0.4 W - with low idle power consumption.
If you add a great price to it ... no wonder why they are so popular ...