The difference is I can upgrade my NixOS without breaking everything hahaha. But it has gotten a lot more popular recently, which I think is your analogy? Or because people always bring it up now lol
The similarities are superficial at best. The only thing similar is that it uses braces for attribute sets (objects) and square brackets for lists. And I guess quotes for strings.
But otherwise it's a full (functional) programming language, with functions, variable bindings, etc.
Flakes aren't perfect, but they are really good for ensuring that you have completely reproducible builds since the version used for every dependency is pinned.
iirc theyre meant to improve reproducibility by using pinned versions of stuff like nixpkgs instead of inheriting from your system which could be a problem if for example someone on 23.11 sends a deriv to someone on 24.05