What is this type of argument called? Commonly used today
For example:
I'm sure all of the republicans crying & lying about "vaccine passports" were out in the streets fighting to change the laws that said HIV+ people weren't allowed to enter the US.
Here, (A) is dismissing republicans concerns with “vaccine passports” stating they are hypocritical. However, by doing so, is (A) also saying that HIV+ laws were appropriate?
Another example
the protests at the capitol were violent, but it needed to be violent to get the message across. The left was fine when the riots for BLM were violent, so they cannot complain now.
This is the tu quoque fallacy
when someone’s argument is discredited solely based on the allegation that their past actions or words are not consistent with their views.
It's also known as the appeal to hypocrisy
an informal fallacy that intends to discredit the opponent's argument by attacking the opponent's own personal behavior as being inconsistent with the argument's conclusion(s)
In addition, this is the same fallacy when used as a defense, i.e. by claiming that one's own actions are justified because the opponent has done the same thing in the past.