Depends on the attack type. If its no damage knockback then time a gap closer, but if its a damaging knockback you can use a shield.