I liked your last paragraph. I believe too that it was detrimental for the lives of those people who immigrated to cities to find jobs at those factories. Jobs that are detrimental to their health in many ways.
In some cases, yes. But I think on balance people who escape the countryside for the city factory jobs are not leaving a comfortable job for the promise of riches but with health risks. The factory/city job offers a much better alternative. An alternative to being a subsistence farmer or a day laborer, or a maid, or the daughter who has to marry at 16-18 and have no chance at an education. In the countryside it's not unusual for people to barely 'eke out' a 'living'. It could be picking up discarded trash and finding something recyclable, etc. Going from the coutryside to working for a Foxconn is like going from line cook at MickeyD's to being exempt salaried in the US with flex time -it's no contest.
As 'unhealthy' as the city job might be, the alternative in the countryside is, for many people, worse. It's a life of a kind of feudalism.