Doug Noll offers a third way when someone yells at you: neither staying silent nor fighting back. Instead, breathe, acknowledge their emotion with a "you" statement, set a boundary once they calm down, then move toward solving the problem together.
Chapters
You think you have only two choices when someone takes their frustration out on you: to either take it or give it back. But that's wrong. If you take it and go quiet, you lose your voice. And if you fire back, the fight gets bigger. So here's what you should do instead: take a deep breath and ignore their words. Look them in the eye and acknowledge what they are feeling with a simple "you" statement like, "You seem really frustrated." Once they start to calm down, set a boundary by saying, "That is not okay," or move toward solving the problem by saying, "Let's figure this out together." Try this the next time someone yells at you and you'll be back to thank me. What do you normally do when someone yells at you?