Afaik, the order of entries in services.xserver.videoDrivers is important.
So when you put "nvidia" before "intel" that gets prioritized.
Other than that you can either have primus or bumblebee for using the dGpu in case of nvidia.
https://nixos.wiki/wiki/Nvidia#Nvidia%20Prime
I am currently suffering from similar issues though. In my case nvidia-offload works, but the intel gpu does not. I found out why (mesa drivers are out of date) but I have no idea how to fix that.
More context here in case your issue is similar: Need help pinning opengl mesa package
Especially try running $ nix run -f channel:nixos-unstable glxinfo