The vast majority of them are spending $20,000 or less. VAT is Thailand is 7% so that's $1,400 in tax. And that's probably overstating things because much of their spending will be on things that go untaxed for one reason or another.
There's only a few thousand of these people in any given country, by most estimates I've seen. Which matches my personal experience. In any given country they will only be in 2-3 cities and if you spend time in those cities you'll be surprised how small the expat circles are even in a city of 10 million.
$1,200 in tax from 4,000 digital nomads is...$5,000,000. Thailand's economy generates $500,000,000,000 a year. The illegal expat contribution is a tiny, minuscule drop in the bucket.
Unsurprisingly, countries (just like neighborhoods that crack down on AirBNB) might want to optimize for people who want to stay long term, adopt their values, become part of the social fabric...not just maximize marginal income from people who will never even try to learn the language and don't have a single local friend.
What's more, the arguments all have a whiff of colonialism to them. If having foreigners working in your country and not paying income tax is so amazing....why don't you get your own country to do it first?
At the end of the day, the countries get to set their own laws. You don't get to ignore their laws because "well I'm an entitled middle class white man (there are effectively zero digital nomads who aren't white men, in my experience) and I'm bringing a lot of money into their economy don't you know!"
"Digital nomad" is just a "white person who is an illegal immigrant".