I think if an actual default were about to happen, the president would have two options:
1) Defy Congress and order the treasury to keep borrowing money. This could result in an attempted impeachment by Congress. The president's defense would be that Congress had passed conflicting pieces of legislation: Budgets and mandatory spending bills on the one hand constrain and require the president to spend money certain ways, and the debt ceiling on the other hand constrains and requires the president to not spend money. Another defense would be that had the president not defied Congress, people would die, the economy would crash, there would be military threats, etc. From the president's point of view, this whole argument and impeachment drama would probably last the rest of their term anyway, and would not block a re-election bid. From a legal point of view, the debt ceiling would increasingly start to look like a dead law or empty tradition. Defiance might be a good strategy for a president in Biden's position, who retains control of the Senate and thus remains unimpeachable. However the whole debacle would be a distraction from the president's agenda.
2) The other option is that the president could announce that the only way to comply with both the debt ceiling and statutory spending laws would be for the Treasury to start printing money to pay for the costs of government. Money creation by this route is different than money creation by borrowing, because the issuance of treasuries takes new cash out of circulation in the marketplace and puts it in an account where it will sit for years, whereas printing money drops cash directly into markets with no offsetting removal of cash from the markets. Thus, this move could set off a new round of inflation while stimulating the economy. #2 would be a good strategy for a president who is facing an imminent recession because the stimulus would likely help shorten the recession. It would also offer the president a convenient scapegoat if they could blame the members of the other party for not raising the debt ceiling and causing the recession and inflation. If the money-printing occurred prior to recession, a president in Biden's shoes could say - "look folks, the Republicans in the House have voted to force the government to print money as its only legal option to keep the country afloat. This will lead to inflation and a recession if it goes on too long. They are destroying the value of the dollar and American's livelihoods..." and most economists would agree with the first part. It could be an incredible political weapon to place the blame, predict the result, and then let the people see exactly the result you predicted. Plus, money printing this way is probably not illegal and impeachable like defying the debt ceiling law would be. However, the president would be wagering on the people accepting their explanation of things. The other side has a voice too, and could say the president's profligate spending caused the crisis. In reality, what the people believe probably has more to do with the size of each party's media megaphones than the actual truth. Also, if the money-printing went on for even a day before a new debt ceiling was passed, it's possible the president would end up holding the long-term political liability for any future inflation, because their opponents could point to that one day of money printing and harp on it forever. There's a risk that going the money-printing route would relieve pressure on legislators to raise the debt ceiling, and thus it never gets raised and the nation becomes stuck on the money-printing track long-term.
In the event of #1, the debt ceiling debate would essentially be resolved, perhaps for good if a court ruled that Congress implicitly sets borrowing levels when it sets budgets and tax rates and cannot create a liability for the president by passing conflicting laws. Big nothingburger. In the 2023-24 configuration of Congress, an impeachment attempt would go nowhere, but 2025 could be another story if Republicans win both sides of Congress. For this contingency alone, #2 probably looks more attractive to Biden than #1. On the other hand, a Republican-controlled Congress could impeach the president for anything (confidential documents stored in a garage for example), so why should Biden worry about this particular angle?
In the event of #2, markets could drop in 2023 like they did in 2022 as participants started to expect much higher interest rates would be needed to offset the inflationary effects of money printing. House Republicans would be under intense pressure to cave, with possibly daily beatings coming from the bully pulpit. However, chaos would be on their side as it was in previous debt ceiling debacles. People consistently (though incorrectly) blame the president for the state of the economy, so Republicans could simply wait for this tendency to take effect and use the worsening conditions to help DeSantis win amid poor economic conditions in 2024. Thus it's not clear Republicans would be incentivized to cave and pass a higher debt ceiling if the president tried to use deteriorating economic conditions as leverage against them. The story of Brer Rabbit and the briar patch comes to mind.
If #1, invest as normal. If #2, short everything.
There is also the chance the president could try out #2 for a while and then resort to #1 if it didn't work, or at least switch to #1 after the blame had been cast. This two-part dance might offer a president the best of both worlds: It would put the president in control of an economic dip blamed on House Republicans followed by a big recovery that could be attributed to the president's bold defiance of them. If a recession is imminent anyway (by all signs it is) then the timing might just work out to associate the entire recession with this Republican-led debt-ceiling issue. Then the president could take credit for the recovery by defying them and returning to borrowing.