If you're riding a european pedelec (pedal assist) up to 25km/h, bike helmet should be fine, if you're riding electric motorcycle (25km/h+, accelerator) then maybe motorcycle helmet is more appropriate.
A while back I had a friend take a dive on an electric scooter. Black eye, broken collar bone, broken lower leg. If you're on two wheel, definitely wear a helmet.