Earlier quoted context omitted.
I am not sure why you are being downvoted. It seems that much of HN has very little knowledge of (and interest in) business operations and employment law in other countries. I see your question as genuinely inquiring about this stark difference from what is common in Europe and other countries.
I didn't downvote the OP but I am picking up a tone of indignation that I don't quite understand. I find this pretty interesting. Here is my take on the situation: Let's say I own a widget factory and you are highly skilled at turning paper clips into widgets. We agree on a price for your time and I hire you to start making widgets. Things are going gangbusters, you produce a ton of widgets and I pay you for the time…
You may have bought raw materials, hired people, set up a warehouse and stocked it with products anticipating my orders, but I don't understand why I should be obligated to pay for your products if I no longer need them.
All contracts generally include terms for termination of the contract. The tone of indignation is in the US, employers determine them unilaterally and employees don't have the bargaining power to do anything about it.