Baby swings/rockers

Is this bad for newborns heads since they’re being rocked back and forth?

worried about the baby shaking syndrome being caused by keeping baby on swing all day while she naps (only way she falls asleep)