In the past they were used by people who wanted to drive out competition. And griefing, but that’s always existing. Everywhere. Even in WoW. Can only ban post facto.
Wardecs were below five million ISK back in the days, which meant literally everyone could just do them, as they were a form of content. The exact reason why they got nerfed heavily is unknown, but most people agree that it was the exaggerated whining of a few people. Note: Back then we did not actually have the situation like it is today, and it is noteworthy to point out (and never forget) that CCP actually caused the current situation all by themselves.
Nowadays wars only seem to occasionally bring actual content. There’s people like @Noragen_Neirfallas who do a really great work with people, getting them to fight or - even more importantly - teaching them how to fight/defend themselves… but well, guys like him are a rare. Also not to forget @Kannibal_Kane, though no idea if he really went back to hiatus. He was a good guy, the best solo war deccer to ever haunt New Eden.
So wars create content and allow people to get rid of competition. They also allow for griefing, not going to deny that. It’s also a form of content, but when the other side just stops playing then that’s a rather one sided affair. I’m part of the HTFU crowd, in a sense, and I’ve learned to understand that there’s simply no way around those who don’t want to fight. They need their own mechanics, but they should not be dictating the game’s direction with their inability to survive in harsh environments. That’s a very un-human way of existing.
And, of course, not to forget that highsec wars are the only way of getting rid of citadel spam, which would just get much worse if they decided to can them without a replacement.
Oh, and the last one … let’s not forget the hub humping degenerates ( © @Ralph_King-Griffin ) who have no balls, no skills, no real life, no dignity, no actual pride, no self respect and no way of ever physically reproducing. They’re something good only (only!) in the sense that everyone agrees that these kind of players are a cancer. That’s good! I guess.
That was pretty much the whole answer to your question. Wars have their good parts, but the mechanic is so broken that they get heavily overshadowed … and by overshadowed I mean a solar eclipse by ■■■■■■■ jupiter which fell out of his orbit, headed straight for earth and now sits in line-of-sight between earth and sun, inevitably crashing into and destroying our planet.