Switching from gas to electric is something I can do all on my own. Switching from gas car to cycling is something that would require major investments from my city and developers. Both are noble goals, but let's not let perfect be the enemy of good. Switch to electric now, and also encourage new roads and new developments to be bike friendly, so that switching to a bike is something that will be viable in 20 or 30 y…
What major investment would be required from the city or developers to set up cycling infrastructure? Painting some cycle lanes onto the roads? Marking a few car parking places as bike parking places? That's all that cycling infrastructure really is, so it's super cheap. A lot cheaper than, say, building charging stations for electric cars.
Paint doesn't do squat for making car lanes safe for bikes.