By using fabric button.
Crochet button with Schoeller Conductive Yarn: Nm 25/1 100% Inox @ Euros 145.00/kg (25,000 metres/kg). The resistance range 100-120 ohm, 30 ohm when stretched per 10 cm.
The button has 1.6k ohm resistance when closed (pushed).
Here are pictures of construction.
The middle pink-white yarn is mixed with conductive yarn. Green and orange yarn are normal yarn. Orange yarn is connecting the 2 sides and closing the button.