CNN  — 

Declaring himself “your president of law and order,” President Donald Trump vowed Monday to return order to American streets using the military if widespread violence isn’t quelled, even as peaceful protesters just outside the White House gates were dispersed with tear gas, flash grenades and rubber bullets. It was all, apparently, so Trump could visit a nearby church.

The episode, which amounted to one of the most highly charged and discordant moments in recent presidential history, came as nationwide unrest escalates and as Trump comes under pressure to demonstrate a modicum of conciliation for a country torn along racial, ideological and political lines.

He did not offer that on Monday, choosing instead to retrench. He called violent protests “domestic acts of terror” which law enforcement would “dominate the streets” to quell.

“If a city or state refuses to take the actions necessary to defend the life and property of their residents, then I will deploy the United States military and quickly solve the problem for them,” Trump said.

With the constant sound of helicopter blades overhead and a steady succession of bangs from nearby Lafayette Park, Trump declared himself an “ally of all peaceful protesters.”

But as he was speaking, peaceful protesters were being urgently dispersed outside the White House gates by police using rubber bullets, tear gas and flash bangs. Several protesters were seen pouring water into their eyes to ease the gas’s sting.

Later, Trump walked across the park to St. John’s Episcopal Church, a house of worship used by American presidents for more than a century that was partially burned in a Sunday evening protest.

“We have the greatest country in the world,” Trump said in front of the church, holding a Bible and surrounded by aides, including national security adviser Robert O’Brien, Attorney General Bill Barr, senior adviser and son-in-law Jared Kushner, chief of staff Mark Meadows, Defense Secretary Mark Esper and press secretary Kayleigh McEnany.

He remained at the boarded-up building for a matter of minutes before returning inside the White House.

Before Trump’s address, a crowd was gathering outside the White House gates ahead of a 7 p.m. ET curfew mandated by the mayor of Washington, including near the church.

A large convoy of military vehicles was seen driving through the White House complex and onto Pennsylvania Avenue before Trump emerged to speak.

Trump said from the Rose Garden he was committed to upholding laws and mobilizing military resources to end nationwide looting.

“My first and highest duty as president is to defend our great country and the American people,” Trump said. “I swore an oath to uphold the laws of our nation and that is exactly what I will do.”

In striking terms, Trump said he would use his entire presidential prerogative – including threatening to invoke a rarely used law dating back to 1807 – to ensure violent protests end, declaring he would deploy “thousands and thousands of heavily armed soldiers, military personnel and law enforcement officers” to bring order.

Trump said justice would be served for George Floyd, the unarmed black man who died after a white police officer knelt on his neck as he was being arrested. He said he, along with many other Americans, was “rightly sickened and revolted” by video showing the incident.

Ahead of his appearance on Monday evening, a debate had raged among Trump’s advisers over how and whether he should address protests that have spread to dozens of cities.

And Trump himself was angered by coverage depicting him holed up in an underground bunker. He told aides on Monday he wanted to be seen outside the White House gates, according to a person familiar with the matter, which is part of what drove the decision to stage the photo-op at St. John’s Church.

Trump and his family were rushed to an underground bunker on the White House complex as protests raged outside the building on Friday evening. Trump wasn’t seen on Sunday and spent most of Monday behind closed doors – leading to concern even from his allies that he was absent at a moment of national crisis.

Many of the President’s traditional defenders – from campaign donors to Republicans on Capitol Hill to some in the conservative media – privately grumbled that Trump allowed several days to pass without addressing the nation or making any formal appeals for unity.

Some outside allies reached out to the White House in recent days to push for an appearance from the President in which he would confront a crisis he has largely watched unfold from behind closed doors or in his underground bunker.

One major campaign donor worried the damage inflicted by Trump’s absence during a historic weekend of violence and pain could alone imperil his reelection.

A growing number of congressional Republicans, even Trump’s allies, also privately said the “caps lock” tweets about tamping down protests using harsh tactics were not helping the situation. Republican Sen. Tim Scott of South Carolina said on “Fox News Sunday” that he had spoken to Trump over the weekend about his inflammatory tweets, which he described as “not constructive.”

Over the weekend, some aides sought to convince Trump not to use violent rhetoric after he wrote on Twitter that “when the looting starts the shooting starts,” warning language like that could inflame an already combustible situation and would not appear presidential.

A senior White House aide said governors and mayors should be the ones responding to the destruction in their respective cities and states – a view at least partially shared by Trump, who has spent days going after local leaders for not calling the National Guard fast enough or cracking down on violence aggressively enough.

In a heated phone call with governors on Monday morning, Trump placed responsibility on the governors for resolving the national crisis and said some of them appeared “weak” in their responses so far.

Other White House officials argued over the weekend against something as formal as an Oval Office address, a person familiar said, out of concern that such a speech could “inflame the situation, not make it better.”

As aides debate how and whether to confront the situation, Trump’s back-and-forth between violent rhetoric and a more measured tone has weighed in the deliberations, one official said. Some advisers wonder whether a presidential address calling for calm would be quickly erased by Trump’s own penchant for escalation and instigation.

CNN’s Jeff Zeleny, Kaitlan Collins, Jim Acosta, Dana Bash and Vicky Ward contributed to this report.