Well, I warned his boss, an elected official, that his Prosecutor harbored such views about the general public. I thought he had a right to know.
In my opinion, don't say something you are going to be embarrassed to stand by, and don't say something that you are not willing to stand up for.
As I have grown more secure in my profession and position in the community, I feel more free to share my opinion on issues. When I was less secure, I kept my mouth shut when it came to controversial issues. Even today, with a big client who I don't want to take a dislike of me, I would hold my piece if he went on a rant about how great Trump is.
I hold my breath when my father in law goes on his pro-trump anti-immigration rants, for the sake of peace at family dinner.