Your question is a bit like asking how a word processor is better than a typewriter... they both produce typed text, but otherwise not comparable.
[1]https://blog.comfy.org/p/nano-banana-via-comfyui-api-nodes
Think of it this way: spreadsheets had a massive impact on the world even though you can do the same thing with code. Dataflow graph interfaces provide a similar level of usefulness.
I'd say that comfy UI is like Photoshop vs Paint; layers, non-destructive editing, those are all things you could replicate the effects of with Paint and skill, but by adopting the more advanced concepts of Photoshop you can work faster and make changes easier vs Paint.
So it is with node based editing in nearly any tool.
They’re about as similar as oil and water.