L.A.
I think both ways needs to be implemented.
First of all teach your child to stand up to the hitter and say
"We do not hit, use your words"
"I do not like it when you hit."
"I will not play with you if you hit."
Then tell your child if the hitter keeps hitting to come and get you "after she has tried to stop the hitter".
Then get both of the children together and
ask your child, "What happened?"..
Your child "She hit me"
You ask "What did you tell her about hitting?"
Your child "we do not hit" or, " I do not like it when you hit" or I will not play with you when you hit."
Then you ask the hitter." Did you understand what she said?" "Are you going to stop hitting?"
Depending on the answer, thank them for using their words and tell them to play fair without hitting. Or Tell the hitter, "daughter says she is not going to play with you anymore because you keep hitting. "