Tell that to Russia, its economy is - military production aside - in shambles due to Western sanctions and especially the brain drain.
The idea of economically enforced peace only works for democratic countries where the government has to show at least a bare minimum of respect towards its citizens, but not in countries that follow the whims of their respective Dear Leader.
Putin is surrounded and supported by people who are probably losing a ton of money right now. When he finally learns his lesson, it's probably going to be a harsh one.
Too bad for them they can only spend it in Russia on Chinese stuff. (My father in law lives in Moscow. Muscovites pay more for old Japanese cars than brand new Chinese cars)
At the time international trade was still fairly minor, so although a war would be deeply unprofitable it'd still be possible. Today's economy looks quite different, with even basic consumer goods coming from overseas. If international trade were to suddenly cease, most major countries would be in serious trouble really quickly.
The most extreme example of this is the European Union. Its economies are so deeply interwoven that they act as a single entity. Separating them to the point that one of its members can independently support a war economy would take decades, so it does indeed make intra-European wars virtually impossible.
Make's war more unappealing to those that are rational, which is the best you can hope for because there is no sure fire way of dealing with the irrational.
Although I think wars do often have an irrational element, economic considerations aren’t the only ones that should influence rational decision making.
War is pretty hard when a decent portion of the thing you need to actually do war are made by the country you're at war with. Sure, you can start a war, but it'll be over when your local warehouses run out two weeks later.
It could be, but are there many historical examples of wars ending for this kind of reason? Typically, no country has its economy set up for wartime production during peacetime. But that can change quickly when there’s a will.
We survived the Cold War because the U.S. and the Soviet Union were able to rationally agree on not using nuclear weapons. I sure believe countries today can rationally agree on avoiding war for fear of the economic consequences.