A long-delayed $19.1 billion disaster aid bill has sailed through the House and headed to President Donald Trump for his expected signature, overcoming months of infighting, misjudgment and a feud between Trump and congressional Democrats.

Lawmakers gave the measure final congressional approval on Monday by 354-58 in the House's first significant action after returning from a 10-day recess. It was backed by all 222 voting Democrats and 132 Republicans, including the GOP's top leaders and many of its legislators from areas hit by hurricanes, floods, tornadoes and fires. Fifty-eight Republicans voted "no," including many of the party's most conservative members.

Trump hailed passage of the bill, tweeting, "Farmers, Puerto Rico and all will be very happy." The Republican president also suggested, incorrectly, that the bill would now see action in the Senate. That chamber had already passed the bill by a sweeping 85-8 vote on its way out of Washington May 23, a margin that reflected a consensus that the bill is long overdue.

But conservative Republicans in the House held up the bill last week, objecting on three occasions to efforts by Democratic leaders to pass the bill by a voice vote requiring unanimity. They said the legislation — which reflects an increasingly permissive attitude in Washington on spending to address disasters that sooner or later hit every region of the country — shouldn't be rushed through without a recorded vote.

Along the way, House and Senate old-timers seemed to outmaneuver the White House, though Trump personally prevailed upon Senate Appropriations Committee Chairman Richard Shelby, R-Ala., to drop a bid to free up billions of dollars for dredging and other harbor projects.

The measure was initially held up over a fight between Trump and Democrats over aid to Puerto Rico that seems long settled.

"Some in our government refused to assist our fellow Americans in Puerto Rico who are still recovering from a 2017 hurricane. I'm pleased we've moved past that," said House Appropriations Committee Chairwoman Nita Lowey, D-N.Y. "Because when disaster strikes, we shouldn't let a ZIP code dictate our response."

The measure also faced delays amid failed talks on Trump's $4 billion-plus request to care for thousands of mostly Central American migrants being held at the southern border. The sides narrowed their differences but couldn't reach agreement in the rush to go on recess, but everyone agrees that another bill will be needed almost immediately to refill nearly empty agency accounts to care for migrants.

"We must work together quickly to pass a bill that addresses the surge of unaccompanied children crossing the border and provides law enforcement agencies with the funding they need," said top Appropriations Committee Republican Kay Granger of Texas. "The stakes are high. There are serious — life or death — repercussions if the Congress does not act."

The measure is largely the same as a version that passed the House last month. Republicans opposed it for leaving out the border funding.

Among the reasons was a demand by House liberals to block the Homeland Security Department from getting information from federal social welfare authorities to help track immigrants residing in the U.S. illegally who take migrant refugee children into their homes.

As the measure languished, disasters kept coming — with failed levees in Arkansas, Iowa and Missouri and tornadoes across Ohio just the most recent examples. The measure is supported by the bipartisan party leadership in both House and Senate.

The legislation is also being driven by Florida and Georgia lawmakers steaming with frustration over delays in delivering help to farmers, towns and military bases slammed by hurricanes last fall. Flooding in Iowa and Nebraska this spring added to the coalition behind the measure, which delivers much of its help to regions where Trump supporters dominate.

The bill started out as a modest $7.8 billion measure passed in the last days of House GOP control. A $14 billion version advanced in the Democrat-led chamber in January and ballooned to $19.1 billion by the time it emerged from the floor last month, fed by new funding for community rehabilitation projects, Army Corps of Engineers water and flood protection projects, and rebuilding funds for several military bases, including Offutt Air Force Base in Nebraska.

Many Republicans opposed funding to mitigate future disasters as part of rebuilding projects when Superstorm Sandy funding passed in 2013, only to embrace it now that areas such as suburban Houston need it. Democrats, for their part, held firm for what ended up as roughly $1.4 billion for Puerto Rico, letting Trump feud with the U.S. territory's Democratic officials for weeks and deflecting political blame for stalling the bill.

___

This story has been corrected to show that more than 130 Republicans voted for bill, rather than "more than 50."