Giving ESP8266 Power wth slide switch

What is a good way to turn off and on a esp8266 with a slide switch? I don't mean to start/end the program, i'm talking about giving the esp8266 power. I'm searching for a circuit and tips.
I have a battery pack with a slide switch which does the same -> if on, then it gives power. But it's too big for my project so i want to make it by myself.