President Trump, spending the weekend at his Bedminster golf resort in New Jersey, attacked the mayor of San Juan on Saturday for "poor leadership" and accused her of conspiring with Democrats to criticize his administration's response to storm-ravaged Puerto Rico.

Trump blasted Mayor Carmen Yulín Cruz in a series of tweets that aimed to deflect blame for the deepening humanitarian crisis on the island and to cast the mounting criticism against him as partisan attacks — from local officials, political rivals and the media.

"The Mayor of San Juan, who was very complimentary only a few days ago, has now been told by the Democrats that you must be nasty to Trump," Trump wrote on Twitter. In another message, he added that Cruz and other local officials "want everything to be done for them when it should be a community effort."

The outburst came as Trump has bristled over accusations from local officials that the federal government has not moved quickly enough to provide support and aid amid widespread power outages that have left residents without air conditioning, while food, drinking water and other basic necessities are in short supply in the aftermath of Hurricane Maria. At least 16 people have died since the storm struck last week, with many others in critical condition, and officials expect the death toll to climb in the coming days.

On Friday, Cruz pleaded for additional help from the Federal Emergency Management Agency, saying at a news conference: "I am begging, begging anyone who can hear us to save us from dying. . . . We are dying, and you are killing us with the inefficiency."

In his response on Twitter, Trump cast Cruz's criticism as "unfair" to the thousands of federal workers who his administration says are now in place on the island, and he praised the efforts of the military and other ­first-responders.

1 of 70 Full Screen Autoplay Close Skip Ad × Puerto Rico devastated in the aftermath of Hurricane Maria View Photos After the Category 4 hurricane slammed into Puerto Rico, many of the more than 3.4 million U.S. citizens in the territory were still without, adequate food, water, electricity and fuel. Flights off the island were infrequent, communications were spotty and roads were clogged with debris. Caption After the Category 4 hurricane slammed into Puerto Rico, many of the more than 3.4 million U.S. citizens in the territory were still without, adequate food, water, electricity and fuel. Flights off the island were infrequent, communications were spotty and roads were clogged with debris. Carlos Barria Buy Photo Wait 1 second to continue.

In a bid to isolate Cruz politically, Trump spoke by phone in the afternoon with Puerto Rico Gov. Ricardo Rosselló and U.S. Virgin Islands Gov. Kenneth Mapp, and later praised both of them on Twitter. Trump called Rosselló a "great guy" and said that Mapp told him FEMA and the military "are doing a GREAT job!" Trump also praised Jenniffer González-Colón, the island's resident commissioner to the U.S. Congress, although he misspelled her first name in a tweet.

And Trump reaffirmed that he and first lady Melania Trump intend to travel Tuesday to Puerto Rico, with a possible stop in the U.S. Virgin Islands, which also is recovering from the hurricane.

"To the people of Puerto Rico: Do not believe the #FakeNews!" Trump wrote on Twitter in the afternoon.

Appearing on MSNBC, Cruz emphasized that she was not trying to be "nasty" to the president and said she remains open to speaking or meeting with Trump.

"I'm fighting to save lives," she said. "That's it. This isn't personal."

She also made clear she didn't plan to stay quiet.

"I will always speak my mind," Cruz told reporters at the Roberto Clemente Coliseum in San Juan. "I don't give a damn."

The president's tone provoked a major backlash among Democrats, community leaders and celebrities who lambasted him for casting blame and appearing insensitive to the suffering of U.S. citizens. Trump is expected to stop by the Presidents Cup professional golf tournament in Jersey City on Sunday before returning to the White House that evening.

Many of the strongest critiques came from female lawmakers, including Sens. Catherine Cortez Masto (D-Nev.) and Kirsten Gillibrand (D-N.Y.), and House Minority Leader Nancy Pelosi (D-Calif).

"When a hurricane hits, there are no Democrats or Republicans--only Americans, families struggling to survive," Pelosi tweeted. "Shameful @POTUS can't see that."

Lin-Manuel Miranda, the creator of the musical "Hamilton," wrote on Twitter that Trump is going "straight to hell," while pop star Lady Gaga wrote to her 71 million followers that "it's clear where the 'poor leadership' lies @realDonaldTrump Puerto Rico is part of the United States. This is our responsibility."

Russel L. Honoré, the retired lieutenant general eventually appointed by President Bush in 2005 to improve the response to Hurricane Katrina, criticized Trump's attack on Cruz.

"The mayor's living on a cot, and I hope the president has a good day at golf," he said on CNN.

Trump's senior aides struck back, echoing the president's assertions that the "fake news" media had failed to tell the full story of the administration's recovery efforts. White House officials distributed an email to news outlets stating that 10,000 federal workers are on the island and that recovery workers have cleared 11 major highways and 50 percent of the major roadways. The military is airdropping supplies to remote regions in the mountains.

Yet the White House's own statistics showed how much work remains: Forty-five percent of residents have access to drinking water from the island's pipelines, and 49 percent of grocery and big box stores and 60 percent of gas stations have reopened.

Republicans in Congress were mostly silent about Trump's attacks on Cruz, with aides to House Speaker Paul D. Ryan (R-Wis.) saying he had spoken about Puerto Rico in his weekly news conference on Thursday and would have nothing more to say on the weekend.

One Republican strategist with ties to the White House said the president's remarks sought to paint Cruz as a partisan, which will make her criticism easier for Trump's base to discount.

"Trump is simply not going to let the San Juan mayor define the U.S. relief efforts when he feels like he is being attacked," said the strategist, who requested anonymity to speak candidly. "His comments are divisive, yet they redefine the mayor's intent as partisan to his base, which is really what matters to him."

Doug Heye, a GOP consultant and former communications director for the Republican National Committee, said he found Trump's tweets "appalling."

"He essentially said Puerto Ricans were lazy," said Heye, adding that the mayor had not said anything negative about Trump and his role in the recovery.

Late Saturday, Trump sought to strike a more positive tone, tweeting: "We must all be united in offering assistance to everyone suffering in Puerto Rico and elsewhere in the wake of this terrible disaster."

But he did not relent in his criticism of Cruz.

"Results of recovery efforts will speak much louder than complaints by San Juan Mayor," he tweeted. "Doing everything we can to help great people of PR!"

To his critics, Trump has seemed more concerned with the reviews his administration is getting than the response itself.

In a Rose Garden news conference on Tuesday, Trump claimed that "everybody has said it's amazing the job we've done in Puerto Rico" and that his team was getting "tremendous reviews."

On Thursday, he tweeted that the federal government was doing "a GREAT job." And on Friday, he cited the death toll in Puerto Rico as evidence of his administration's success.

"The loss of life — it's always tragic — but it's been incredible the results that we've had with respect to loss of life," Trump told reporters as he left the White House en route to his golf club in New Jersey. "People can't believe how successful that has been, relatively speaking."

Presidential historians said Trump has failed to frame the catastrophe in the proper context.

"President Trump keeps talking about ratings and reviews," said Douglas Brinkley, a historian and professor at Rice University. "It's kind of a TV mentality he has. He's acting like it's a detached problem."

In an attempt to blunt criticism, Trump has stressed the degree of difficulty the response in Puerto Rico presents.

At the top of a speech devoted to tax policy on Friday, Trump ticked off a series of issues, including that Puerto Rico's infrastructure was already in "very, very poor shape," that the U.S. territory is saddled with "tremendous" debt and that it's an island.

"This is an island surrounded by water — big water, ocean water," Trump said.

Trump's posture has posed a particular challenge for territorial and local officials who want to stay in his good graces but also leverage the most help they can get for their people.

Just a few days ago, Trump tweeted a "thank you" to Cruz for what Trump characterized as her "kind words" about the recovery effort.

Trump advisers say it has been important for the president to boost the spirits of first responders by praising their work in tweets and in public remarks. Doing so while also remaining sensitive to the victims of the hurricanes presents "a balancing act," said Barry Bennett, a Trump adviser during last year's election.

For several days now, Trump has accused the media of not giving his administration enough credit for its efforts in Puerto Rico's recovery. That attack intensified with Saturday's tweets, including one in which Trump said the "Fake News Networks are working overtime in Puerto Rico doing their best to take the spirit away from our soldiers and first R's. Shame!"

As for Cruz — who appeared on CNN Friday night wearing a T-shirt reading, "Help us we are dying" — she said on MSNBC that she would like Trump to visit decimated towns to see the public's "passion for life, see what we are doing to get back on track and listen to their hearts."

She added that "one can visit as a photo op, or one can visit to make sure that things get done the right way."

Wagner reported from Washington. Arelis R. Hernández in San Juan, Puerto Rico, and Kelsey Snell in Washington contributed to this report.