There is a strong belief that an unborn child is affected during an eclipse, and hence a woman is asked to go to bed alone and sleep through an eclipse or just be in bed.
This sounds like grandma's advice but it has a scientific basis. Time is increasingly proving that much of grandma's traditional advice has a scientific basis. During some of the solar eclipses, there may be harmful cosmic rays in the atmosphere, which is why scientists ask you not to see it directly but through dark glasses or through a reflection in the water. It is, therefore, best for pregnant women to keep away from sunlight and not watch an eclipse. This will protect her from harmful effects of the sun.
It is safest, therefore, for pregnant women to sleep through eclipses.