As a candidate, Mr. Trump vowed to ban all incoming Muslims until leaders could “figure out what the hell is going on.” Later, he backed away from a total ban on Muslims but promised “extreme vetting” of those trying to come to the United States.