If you have the cash to be able to buy the house outright why would you default in the first place? Otherwise, after a default (which likely includes bankruptcy) you will be unable to get credit.
Because the house is worth less than the loan... you don’t have to go bankrupt to default on non-recourse home loans as far as I know.