I'm looking for advice on how to deal with these situations in perhaps a classier way.
I'm in my 30s. I have a real, real problem with women demanding that I behave a certain way or do something they want me to do. It triggers me into almost a rebellious-teen mode and I feel like I'm snarky and unkind in response. I would like a better, classier, response to these things.
Example.
I broke with up a guy I was seeing. Vented to a friend, who is around my age. Of all the things I complained about, she honed in on his drinking (which was really out of the blue, because she drinks, her husband drinks, so I don't know where this is coming from). She said to me, "See! That's why you can't date a man who drinks! You MUST PROMISE ME! PROMISE ME RIGHT NOW that you will NEVER date a man who drinks AGAIN!"
I gave her a side eye and just said, "Yeah." The drinking wasn't the sole issue. And no, I'm not going to promise I'm never going to date a man who drinks again. Alcoholics are a problem sure but if we have wine with dinner, calm down. I'm not your child.
But I threw shade and she felt it, and I wish I handled it differently, but I don't know what that looks like.
And it's in particular to these forceful, demanding attitudes and commentary. Like a parent berating their child. Coming from my peers, that just infuriates me, although I can see they are well-intentioned. And it's usually out of the blue--these people aren't like this all the time, it's just occasional one-offs, but man it triggers me.
How do I handle it better?
By addressing the issue directly, head-on. Clearly communicating your feelings. Basically you tell them exactly what you just told us. Explain that (while you understand they probably have good intentions) they come across as demanding and condescending when they talk at you with useless advice as if you was a child. Tell them that makes you feel uncomfortable because you are the same age as them. So they shouldn't be talking to you that way. Ask them to be more respectful.
About the drinking comment, you could directly tell her what you just told us: "How is drinking an issue? You drink too. What? Should I stop hanging out with you because you drink? Your advice sounds rather hypocritical and nonsensical."
Call it out for what it is.
If they are truly well intentioned, just misspoke, then they won't have an issue with you speaking your mind. If they react with hostility, then (yes you will have more conflict, but) you will (also) know that they never considered you as their friend. Better to have their cards out in the open.
Nothing wrong with direct and clear communication. If you have something (negative) to say, just say it. Don't hide it and pretend that everything is fine. The problem of passive aggressive responses and sarcasm as a response is that it lacks clarity and lacks open and honest communication. And you can't build a friendship on dishonest communication or lack of communication. It's okay to talk and ask clarifying questions to improve mutual understanding. We oftem assume the other person understands us already, but it's safer to check, and to over-explain, than to just assume the other person 'gets it', and to leave them with a short one liner. If you care about maintaining that particular friendship.