There are efforts to shift to hydrogen electrically extracted ("electrolysed") from water, with the electric power obtained from renewables, but it is very early days. If your electrolysers and ammonia synthesis equipment are not too expensive, you can operate just when sun is out or wind blows, and not need to rely on stored or imported energy, or back-up generation. But high capital cost may favor 24/7 operation even at times when power costs more.
The world today produces ammonia in the millions of tons annually, but will produce many times as much when ammonia becomes a favored liquid fuel. It will be synthesized using solar in the tropics, and wind where that is reliable, and exported for backup generation. Nobody will need to store more energy than a week or two's worth, because when you expect to run low you order in.
But it's wrapped up in the 10x price increase in non-self sourced power and European politics. For the right market, and product it's fine. That market disappeared when discretionary spending shrank in the heartland markets and they made a decision to minimise capex without hedging their power cost inputs. (Or came to the end of the hedge)
So it's a pivot to markets either with cheaper power or with other cost issues in fresh green leafy veg and micro herbs. Ones with less or expensive water, who are also making a pivot to green energy (hint: as they say.. Arabian peninsula) come to mind.
Vertical farms aren't the only industrial sector to come unstuck on assumptions about power input cost. Lots of German industry assumes cheap gas.