Each state can choose to award its electoral votes however it likes, BUT that decision must be on its own. Entering into an agreement or compact with another state to award its electoral votes according to the compact is clearly prohibited by the Constitution (unless Congress gives its consent first).
Two words, Faithless Electors.