Death for something as complex as the human body isn’t a binary state.
Death is irreversible by definition, so you did not die.
Presumably you were resuscitated before the electrical activity in your brain stopped? My understanding is that's how we define brain death, as the cessation of electrical activity in the brain.
You have a point. Medically induced coma such as with pentobarbital can “flatline” the brain, eliminating electrical fields. After weaning the pentobarbital patients have their memories intact.
If all electric fields were to disappear your brain would collapse into a point...