I wasn't given any medications until after I had given birth. I also placed my daughter for adoption shortly after, so I didn't take any psychotropic meds until sometime after I weaned her off of nursing her. At least that is what I can faintly recall, as my dissociative disorder was really bad back then. But my daughter was in good hands.
I don't do well with psychotropic medications at all. I tried them for a while, but then the doctors had taken me off of them completely after I was later diagnosed with a dissociative disorder. I did much better with just short-term anti-anxiety medications (ativan/lorazepam) and sleep aids (ambien) and talk therapy (to help me learn coping skills in lieu of medications).
But some people do need medications. I heard that there are many safe medications for pregnant and nursing mothers. I don't know what they are though.
You bring up a good question!