Contrary to what I've implied in "How to use a spray bottle as negative reinforcement?" this is one exception of the case.
I have not used a spray bottle, but instead I've kept a glass filled with very small amount of water near the place(s) where my kittens have liked to play with electrical wires. When I noticed anyone of them playing with wires I've sneaked near, taken the glass of water (placed near the place beforehand), then waited a short moment, and finally dropped the water on the kitten. I've kept the amount of water so small that I haven't feared shortcircuiting anything, not even felt a need to wipe the spilled water off the floor afterwards.
What is different between a spray bottle and a tiny amount of water dropped from a glass is in the way the water falls on its target. Spray bottle makes a squirt that has direction and length, while a drop is a single point in time-and-space when it lands on the kitten.
Most of the time kittens are so focused on the small area immediately around them that they can't really figure out where the water came from. I'm not standing quite next to them, and not moving, so they (usually) haven't made a connection between me and the water. What is right there in front of the kitten is the wires, and s/he was playing with those wires, which makes an obvious connection between the unpleasant surprise and the wires. So far I've had good results with this method.
Adult cats are far more observant to their surroundings. I'm quite convinced that this method would fail to make the wanted change in their playing with wires. I have one adult cat who likes to chew thin wires, like headphones cables and batterycharger wires. I haven't even tried to train him away from this habit, instead I've just removed all thin wirings from his reach. Somehow he still finds all of those that I forget to hide. Casualties of the last year: four headphones and three battery chargers.