I live in Indiana (Trump Country). Trump brings to the Republican party many people who you wouldn't think would be traditional republicans (working class). Trump also kept the usual republicans (who else were they going to vote for, they couldn't let Hillary Clinton pick supreme court Justices). So it was a coalition which is how you win at politics. Trump can be crazy but everyone knows in the USA, it has become the courts that decide everything important, People vote for Trump because of the supreme court.
Obama won in 2008 and 2012 because he generated a huge African American turnout, but wasn't threatening to white people, and Health care is something people need and is expensive. He was just a better candidate than Hillary Clinton. The bitter, cling was a mistake but he wasn't getting many of those people who would be offended by that.
Both Obama and Trump are likeable.