Bike swingarms, being simpler versions of a car's trailing arm suspension, also exhibit this anti-squat under accel and anti-dive under decel behavior. The forks, however, do not exhibit any of that behavior.
Imagine you have the rear wheel on a motorbike locked up so that the wheel and swingarm are one solid unit pivoting in the frame. If you try and push the bike backwards, the rear wheel resists and produces an anti-clockwise (looking from the right side with the front to our right) torque around the swingarm pivot, raising the rear of the bike. This is what happens under accel. Vice versa for braking.