If the Electoral College is going to subvert the choice of the majority of voters, its Electors might as well do their duty while they're at it. They probably won't do it, since Electors are generally chosen on the basis of proven party loyalty. But the members of the Electoral College should take a close look at what Donald Trump has done and said both prior to and following the election. And if they are not satisfied that he should be president, they should should their duty as Americans and not vote for him.
Given Trump's repeated defense of Russian government hacking on behalf of his campaign, the allegations that he owes tens or hundreds of millions of dollars to Russian oligarchs, and his oft-stated intentions to continue to remain in close control of his business interests while benefiting from his position as President, there are plenty of legal grounds for Electors to reject Trump as President under the Constitution's emoluments clause:
Article I, Section 9, Clause 8:
No title of nobility shall be granted by the United States: and no person holding any office of profit or trust under them, shall, without the consent of the Congress, accept of any present, emolument, office, or title, of any kind whatever, from any king, prince, or foreign state.
The notion that the Electoral College should perform its actual constitutional function -- electing a person fit to be President of the United States -- is probably a shock to a lot of folks. But this is already getting serious consideration from some of the Electors themselves. One Republican Elector -- Christopher Suprun from Texas -- has already declared his intention to not vote for Trump: Why I Will Not Cast My Electoral Vote for Donald Trump. (New York Times, Dec. 5, 2016.)
A group of 10 Electors have called for an intelligence briefing of Electors on the topic of Trump's ties to Russia before the Electoral College convenes, so that they can better assess his fitness for office: Electors demand intelligence briefing before Electoral College vote. (Politico, Dec. 12, 2016.)
The Electoral College's constitutional duty is clear, as outlined by Alexander Hamilton in Federalist Paper No. 68 (Avalon Project, Yale University):
Nothing was more to be desired than that every practicable obstacle should be opposed to cabal, intrigue, and corruption. These most deadly adversaries of republican government might naturally have been expected to make their approaches from more than one querter, but chiefly from the desire in foreign powers to gain an improper ascendant in our councils. How could they better gratify this, than by raising a creature of their own to the chief magistracy of the Union?
The process of election affords a moral certainty, that the office of President will never fall to the lot of any man who is not in an eminent degree endowed with the requisite qualifications. Talents for low intrigue, and the little arts of popularity, may alone suffice to elevate a man to the first honors in a single State; but it will require other talents, and a different kind of merit, to establish him in the esteem and confidence of the whole Union, or of so considerable a portion of it as would be necessary to make him a successful candidate for the distinguished office of President of the United States.
To sum up, the Electoral College was designed specifically to prevent a corrupt demagogue beholden to a foreign power from becoming president. This is its exact purpose.
If the Electoral College fails to elect a president by a majority, the election gets thrown to the US House of Representatives. The likely outcome there would be to ultimately install Mike Pence as President. If that happens I will undoubtedly hate every policy choice Pence makes.
But at least he's not a corrupt Russian stooge.
I consider the Electoral College to be a generally bad idea that should be replaced by a direct vote of the people. But if it manages to prevent Donald Trump from becoming our president I'll have to take back every bad thing I've ever said about it.
As I said at the top, I doubt it'll happen because the partisan backlash for Electors who don't vote for Trump would be severe if they don't manage to prevent Trump's election. And for some of them there would be legal consequences for failing to vote for Trump, even if the Republican Party kept the White House. But the constitutional and legal grounds for refusing to vote Trump are also clearly present.
If Republican Electors value their patriotism before their party, they will demand that intelligence briefing. And then they will vote their conscience.