WASHINGTON — Democrats and Republicans slammed President Donald Trump on Wednesday after Turkey launched a military operation in northern Syria, three days after Trump announced that he was withdrawing U.S. troops from the country's border region.

Lawmakers from both parties warned that Trump’s move was dangerous, with some predicting that it would only bolster the Islamic State militant group.

Sen. Lindsey Graham, R-S.C., a defense hawk and Trump ally, wrote on Twitter that if reports were accurate about Turkey entering northern Syria, “a disaster is in the making.”

“Pray for our Kurdish allies who have been shamelessly abandoned by the Trump Administration," he tweeted. "This move ensures the reemergence of ISIS."

Pray for our Kurdish allies who have been shamelessly abandoned by the Trump Administration. This move ensures the reemergence of ISIS. — Lindsey Graham (@LindseyGrahamSC) October 9, 2019

Graham wrote that he would lead an effort in Congress to make Turkish President Recep Tayyip Erdogan “pay a heavy price” for the incursion into Syria and urged Trump “to change course while there is still time by going back to the safe zone concept that was working.”

Later Wednesday, the South Carolina senator said he and Sen. Chris Van Hollen, D-Md., had agreed to legislation to sanction Erdogan and his top officials' U.S. assets, as well as those pursuing military and energy transactions with Turkey, unless the country ends its operation in Syria.

I am pleased to have reached a bipartisan agreement with Senator @ChrisVanHollen on severe sanctions against Turkey for their invasion of Syria.



While the Administration refuses to act against Turkey, I expect strong bipartisan support. pic.twitter.com/Ph5fIVt7k3 — Lindsey Graham (@LindseyGrahamSC) October 9, 2019

In an interview with Axios on Tuesday night, Graham said of Trump, “I think he's putting the nation at risk, and I think he's putting his presidency at risk.”

Van Hollen wrote on Twitter earlier Wednesday that the sanctions legislation was being finalized.

"Senators on both sides of the aisle won't support abandoning the one regional group most responsible for putting ISIS on its heels," he wrote.

Rep. Will Hurd, R-Texas, tweeted in response to a threat from Graham to sanction Turkey, “Just as the Kurds had our backs against ISIS, we must have theirs. The U.S. must do whatever it takes to hold Turkey accountable for compromising our security.”

Rep. Liz Cheney, R-Wyo., the House Republican Conference chair and daughter of former Vice President Dick Cheney, who advocated for the invasion of Iraq in 2003, tweeted Wednesday, “News from Syria is sickening. Turkish troops preparing to invade Syria from the north, Russian-backed forces from the south, ISIS fighters attacking Raqqa. Impossible to understand why @realDonaldTrump is leaving America’s allies to be slaughtered and enabling the return of ISIS.”

News from Syria is sickening. Turkish troops preparing to invade Syria from the north, Russian-backed forces from the south, ISIS fighters attacking Raqqa. Impossible to understand why @realDonaldTrump is leaving America’s allies to be slaughtered and enabling the return of ISIS — Liz Cheney (@Liz_Cheney) October 9, 2019

And Sen. Susan Collins, R-Maine, released a statement saying she had said on Monday that "Trump's decision to abandon the Kurds, our major ally in the fight against ISIS, was terribly unwise. Today, we are seeing the consequences of that terrible decision. If the reports of Turkish strikes in Syria are accurate, I fear our allies the Kurds could be slaughtered.”

As the denunciations from lawmakers mounted, the White House responded with a statement from Trump that said the United States did not endorse the invasion and had "made it clear to Turkey that this operation is a bad idea."

"From the first day I entered the political arena, I made it clear that I did not want to fight these endless, senseless wars — especially those that don’t benefit the United States," Trump said.

The president added that Turkey had committed to protecting civilians and religious minorities, including Christians, ensuring the military action would not cause a humanitarian crisis, and making sure ISIS does not reconstitute.

"We expect Turkey to abide by all of its commitments, and we continue to monitor the situation closely," Trump said.

Trump stridently defended the removal of U.S. troops from the Turkey-Syria border in a series of tweets earlier in the day.

“GOING INTO THE MIDDLE EAST IS THE WORST DECISION EVER MADE ... IN THE HISTORY OF OUR COUNTRY!" Trump wrote. "We went to war under a false & now disproven premise, WEAPONS OF MASS DESTRUCTION. There were NONE! Now we are slowly & carefully bringing our great soldiers & military home. Our focus is on the BIG PICTURE! THE USA IS GREATER THAN EVER BEFORE!”

Asked in a CNN interview whether the White House backs Turkey's action, Erdogan's senior policy adviser, Gulnur Aybet, said Trump and the Turkish president "have reached an understanding over precisely what this operation is." Aybet added that the two leaders would meet at the White House next month to discuss further details, including what to do with captured ISIS fighters.

On Wednesday morning, House Minority Leader Kevin McCarthy, R-Calif., a close ally of the president, blasted the Turkish operation but stopped short of criticizing Trump.

“A Turkish military advance into Syria threatens to halt momentum against ISIS, directly assaults our SDF partners, and could give the likes of al-Qaeda and Iran new footholds in the region," he tweeted. "Turkey should stop immediately and continue to work with the US to secure the region."

A Turkish military advance into Syria threatens to halt momentum against ISIS, directly assaults our SDF partners, and could give the likes of al-Qaeda and Iran new footholds in the region. Turkey should stop immediately and continue to work with the US to secure the region. — Kevin McCarthy (@GOPLeader) October 9, 2019

Democratic lawmakers laced into Trump after Turkey's president announced that the military operation had begun.

Florida Rep. Donna Shalala called Trump’s decision to withdraw troops from Syria "the worst kind of betrayal” of the Kurds, whom the U.S. had vowed to protect.