What finally helped me break out of those bad habits was reframing who I was trying to convince of an argument. Let's face it, it's highly unlikely you're going to ever convince someone you're directly arguing with online just by the simple fact
you're arguing, which often suggests some sort of impasse.
Instead, argue as if you're trying to convince the bored reader who has climbed down through the comments (for some reason), who has found value in this discourse and is trying to get more or better perspectives. That is someone you can convince of your position.
It's been a lot easier to engage in text discourse ever since I had that epiphany, because instead of taking every bait and trying to correct every wrong, I'm only engaging with folks arguing with data, with perspective, with good faith more often than not. That leads to better outcomes, I believe, instead of just contributing to so much noise.