The sense I got throughout the Brexit ordeal was that 'Leave' supporters were regarded as not just wrong, but monstrous. Racists, basically, with their hatred of anyone non-white being a driving force behind their vote. That sounds like a great way to demonize your opposition, and it is... but it runs two risks.
First, you have the nightmare scenario where you go all-in on calling your opponents (and anyone who supports him) a horrible, wicked racist - and then the bastard goes on and wins anyway. The only conclusion one can draw from that is that racists are actually pretty powerful and numerous, capable of winning elections. Nothing de-stigmatizes like a loss, and the result is that 'racism' loses power as a term. The one thing worse than having an accused racist win in the political arena is having an admitted racist win. Thankfully, that hasn't happened yet - but if the former keeps happening, the risk that the latter will take place starts to grow.
Second, and arguably worse in some ways, is that it actually cripples your ability to get much of anything done. Here's a funny thought re: the whole Brexit thing. I imagine many of the people who voted to leave could have been mollified with some concessions. Sure, they would have been sacrifices, but at this point who in the Remain team wouldn't have made some sacrifices to keep the EU? But... who makes concessions to evil, wicked racists? People would sooner make concessions to ISIS (and judging by the number of times ransom money has been paid to them, this isn't exactly news anyway.)
Notice that during the post-vote freakout seeking what largely seem like illusory ways to avoid the UK leaving the EU, no one's talking about making concessions in order to stay. It's all fantasies about forcing a revote with reworked rules, or overruling the referendum, etc. Literally the majority of voters are viewed as monsters who can't be reasoned with and whose desires don't count. (I notice the 'You robbed our youth of their desires!' schtick has started to die down upon realizing the youngest eligible voters were also the ones least likely to vote, by the by.)
I'd say people should learn from this, but I don't believe most are capable of it anyway, so I won't bother.