How do you survive with such huge amount of credit card debt?

So I saw on X a post about this, and apparently it's quite common for people to have debts that are half of their monthly wages, and sometimes even more than what they earn. So basically they work to pay debt and they have no money left. First of all I don't understand how anyone would get to this situation in the first place. And secondly I don't understand how this people survive. Personally, I think that if I ever got into that situation I'd try to sell everything I can sell to pay the debt before it spirals out of control, or see if I can declare bankruptcy