The Art of Electronics has a good section on debouncing switches. There are various analog and digital ways of doing it, from R-C smoothing to latches to debounce ICs to microcontrollers.
If you want a thoroughly obsolete look at debouncing, I got a debouncing module from an IBM 705 computer (1954). This module was built from 8 vacuum tubes and a pile of resistors and other components. I powered it up with an inconvenient set of voltages (+140V, -60V, -130V) and actually got it to work: http://www.righto.com/2018/01/ibm-mainframe-tube-module-part...
If you want a thoroughly obsolete look at debouncing, I got a debouncing module from an IBM 705 computer (1954). This module was built from 8 vacuum tubes and a pile of resistors and other components. I powered it up with an inconvenient set of voltages (+140V, -60V, -130V) and actually got it to work: http://www.righto.com/2018/01/ibm-mainframe-tube-module-part...