Here's the thing: you can't switch over an assembly line to make a different product that quickly. A large corporation that manufactures gasoline automobiles cannot abruptly switch to manufacturing electric ones.
First off, there's the fact of the inventory of parts. The supply lines for automobile manufacturing are now largely built on "just in time" delivery, so that the factory gets its supply of left front fenders from the stamping plant just as their on-hand supply runs out. This also goes for things like engines and batteries. If your pipeline is full of gasoline engines you can't just abruptly change that to electric motors. Trying to do so puts your gasoline engine factory out of business until it can start making electric motors, and the technologies used to do those two things are vastly different, so you'd be laying off a lot of foundry workers and hiring people who make electric motors.
Meanwhile, you need to get your electric motors from somewhere. You can't just dial up Radio Shack and order forty thousand 50 kilowatt electric motors, you know. And you're doing this, by the way, at a time when every other auto manufacturer is doing the same thing. Factories are not infinitely scalable; they need time to ramp up production and then they have a certain maximum output that cannot be exceeded. So you have a shortage of electric motors to contend with.
Ditto, by the way, for the controller systems, and for the batteries. They do not grow on trees. And the industrial infrastructure is supplying the raw materials for all these things at a certain rate, which will not change immediately, either. Copper and aluminum and cobalt and lithium, and a host of other things. So you have a shortage of the raw materials that you need to make the components.
Shortages mean idle factories while the shortages are sorted out. Which means unemployment--lots of it. And idle factories cost their owners a hell of a lot of money, which means less profit and less taxes and less investment in further development.
So now, all new cars are electric. Everyone who buys an electric car needs a charger put in his house; we can be generous and say that charger manufacturing was ramped up at the same time all the difficulties with switching over to all-electric production was done, so this is a freebie.
What is not a freebie, though, is the electricity supply. Power companies need to drastically expand generation capacity, and they cannot do it with windmills and solar panels. If the government mandates only "renewable" energy, there ends up being massive brownouts since renewable cannot supply power on that scale, not reliably, not 24/7. Everyone needs to charge his electric car, and he cannot. There is literally not enough electricity to go around, and so it will become expensive--at times, prohibitively so.
And once the generating capacity is there, you still need to beef up the distribution infrastructure to get that electricty to everyone, because the existing infrastructure is not built to handle industrial, domestic, and transportation energy demands. It's only built for the first two, and transportation uses an enormous amount of energy.
So you need to string wires, and the copper market is still recovering from when you were ramping up motor production (and then generator production) so it costs a packet to string all those wires, making electricity expensive--and since you've largely electrified your economy, energy costs hit everyone harder as the cost of electricty skyrockets.
So the Big Green Depression lasts for a rather long while. Quite a lot of people in first-world nations end up freezing to death in the dark. But hey! You stopped the global warming THAT ISN'T HAPPENING AND HASN'T TAKEN PLACE SINCE 1998 so pat yourself on the back for caring about the environment!
*rolleyes*
This is why you give automakers time to make the switchover, you economically illliterate, communist shithead.