A little help with nvidia-prime and xorg configuration

I don’t think I fully got what you’re trying to do but I guess you want to conditionally add nvidia options on top of the system generated ones. That can be achieved by using the OuputClass directive, i.e. cretae a file
/etc/X11/xorg.conf.d/10-nvidia-myoptions.conf

Section "OutputClass"
    Identifier "nvidia"
    MatchDriver "nvidia-drm"
    Driver "nvidia"
    (your options go here)
EndSection

then whenever the nvidia kernel driver is loaded, the options set get applied to the Xserver.