My DD is like this a bit, mainly when she's having a tantrum (usually caused by me telling her she can't steal all her twin brothers toys for the sake of it!) she then has a meltdown and starts flailing, recently she's taken to swiping at my eyes with her rather sharp nails
.
My DD is 2yo and I will put her on my lap (with her facing away to minimise risk of her actually scratching my eyes) I'll place my arms around her securely enough to hold her in place, rest my chin on the top of her head and rock her side to side, explain that hitting is wrong and why, as calmly as I can and I try to keep my voice quiet so she has to quiet herself to listen - it can take a while but I keep going until she starts to settle.
All the while I say I understand why it must be hard for her to hear 'no' and that her emotions aren't invalid but her behaviour is wrong when it comes to hitting out at me or her brother.
It can take a while, usually leaves me with ringing in my ears from the piercing wails and aching arms from having to hold her without pinning her (if that makes sense?) and since implementing this I've at least come away with less injuries!
Now I don't know the age of your DD (or strength!) - but I adapted mine from the technique of holding the childs arms to their sides, getting down to eye level and explaining face to face, my DD isn't quite at the stage where I can do that one, so this was the next best thing I could manage.
Good luck OP, my little sister was a biter when we were growing up, but it wasn't pleasant to live with so I hope you see improvement from your DD soon 