Dwight and Andy - The Office
They were nemesis turned besties. In fact, their mutual anger with Angela for cheating on them both was what helped cause a friendship to blossom.
Joey and Chandler - Friends
Chandler spent quite a few episodes beating himself up over his feelings for Joey's girlfriend. In fact, he even stayed in a box for hours and gave her up to prove his loyalty to Joey. But Joey, of course, wanted Chandler to be happy, so he encouraged him to go after the girl he loved.
James and Winn - Supergirl
Even though they were both in love with Kara, James and Winn showed nothing but respect for each other. While neither of them actually ended up with her, they both did get an awesome new bff.
Blair and Serena - Gossip Girl
Blair and Serena got into all sorts of fights. They both dated Nate and they both dated Dan which did cause some issues in their friendship. But at the end of the day, they remained best friends regardless of their relationship statuses.
Monica and Fallon - Dynasty
Monica may have been out for revenge when she had an affair with Culhane, but it didn't keep Monica and Fallon apart. It took some time, but these two ladies have been best friends since high school and there was no way a man was going to ruin that.
Bay and Daphne - Switched at Birth
Bay and Emmett were an unlikely pairing, but they did end up working well together. However, Daphne was a bit jealous of Bay's relationship with her best friend. Thankfully, it didn't impact their friendship too much or their love for each other.