I always find this comparison a little... silly? I dunno, there’s probably a better word, but I can’t think of one right now.
Nix focuses on reproducible build declarations and development environments, while Docker focuses on self-contained, distributable sandboxes for code execution.
You can certainly try to use Docker to manage development environments or reproducibly build software, but that’s a secondary concern of the system. You’re probably right that these sorts of posts tend to have a “Nix hammer in search of a nail” feel, but the inevitable comparison to Docker always feels cheap to me I guess.