Most fabs build their own separate power grid.
And Japan, South Korea, and Taiwan are also energy poor states that have been able to maintain capacity.
The energy excuse is true for some manufacturing processes like automotive in CEE which were pants that were built in the 1990s to 2000s and leveraged Russian ONG, but is a red herring for a lot of other manufacturing processes in Europe.
European states have a coordination problem as Draghi pointed out 2 years ago.
TSMC alone uses 1/8th of Taiwan's electricity (and rising). They make it work.
https://spectrum.ieee.org/taiwan-semiconductor
https://www.datacenterdynamics.com/en/news/tsmc-could-accoun...