If said electronics are connected to a power outlet with an on/off switch, would the electricity surge find its way into the appliance when the outlet is in the off position?
A regular switch is no match for a lightning strike, there is only a small air gap and it does not take much for an arc to jump over it.
You can often see this even with your regular mains voltage, especially if you have some inductive load (anything with a transformer) attached. A small spark arc is visible when you flick the switch.
Usually more like a 2 to 4 mm gap. A direct strike won’t even notice that. It already jumped thousands of meters lol. I’ve had electronics destroyed sitting on a wooden table that weren’t even plugged in (battery powered) when lightning struck a tree 10 meters from my house. I don’t think there was any arcing to my house, so it was most likely just EMP from the blast (which blew small parts of the tree through exterior and interior walls into the living room)
I’m now in the process of finishing my new all concrete house with 12” solid walls lol. Screw lightning. It’s not a rational reaction, but it’s my reaction.
You can often see this even with your regular mains voltage, especially if you have some inductive load (anything with a transformer) attached. A small spark arc is visible when you flick the switch.