President Trump endorsed a short-term increase in the nation's debt limit suggested by Democratic leaders Wednesday, a strategy that House Speaker Paul Ryan, R-Wis., had already rejected as "ridiculous."

In a joint statement Wednesday, Senate Minority Leader Chuck Schumer, D-N.Y., and House Minority Leader Nancy Pelosi, D-Calif., said in their meeting with Trump and fellow congressional leaders, "the President and Congressional leadership agreed to pass aid for (Hurricane) Harvey, an  extension of the debt limit, and a continuing resolution both to December 15, all together. Both sides have every intention of avoiding default in December and look forward to working together on the many issues before us."

Trump confirmed the deal to reporters aboard Air Force One on his way to North Dakota for a speech on tax reform.

"We had a very good meeting with Nancy Pelosi and Chuck Schumer. We agreed to a three-month extension on debt ceiling, which they consider to be sacred — very important — always we’ll agree on debt ceiling automatically because of the importance of it," the president said. "Also on the CRs and also on Harvey, which now we’re going to be adding something because of what’s going on in Florida — but we had a very good meeting. We essentially came to a deal, and I think the deal will be very good."

The federal government is running out of borrowing authority, which officials say must be increased to pay for existing obligations, including hurricane relief efforts.

The House passed a $7.9 billion aid package Wednesday for victims of Hurricane Harvey, and the Senate is expected to attach a debt-limit extension to that bill. House conservatives have balked at this idea, because they want to tie the debt limit to spending cuts in other federal programs.

Congress also has to pass a spending bill by Sept. 30 to keep the government open, but the most likely scenario is passage of a short-term "continuing resolution" that simply extends current funding levels for a few months while Congress works out a longer-term spending deal.

The proposal Schumer and Pelosi say Trump has endorsed would create a December deadline for both the debt limit and the spending package.

Before the White House meeting, Ryan said the Democrats' proposal is "a ridiculous idea."

"We've got all this devastation in Texas, a Hurricane in Florida, and they want to play politics with the debt ceiling? I think that's ridiculous and disgraceful that they want to play politics with the debt ceiling ... To play politics with the debt ceiling like Schumer and Pelosi are apparently doing I don't think is a good idea."

But other House Republicans said it was not such a bad plan. "A short-term increase in the debt ceiling so that they can handle this is a sensible thing in my view," said Rep. Tom Cole, R-Okla., noting that it would give conservatives another opportunity to argue for spending cuts. "That’s not like an 18-month deal ... we’ll still have to come back and deal with the larger spending issue."