Religious change preceded economic change in the 20th century:
http://advances.sciencemag.org/content/4/7/eaar8680
They reviewed a broad selection of countries over a 100 year period of the 20th C, and they say: "... tolerance for individual rights predicted 20th century economic growth even better than secularization."
Secularization precedes economic development, and so it isn't increased prosperity that causes reduced religious adherence.
Increased regard for individual rights precedes economic prosperity.
I found this link through Andrew Ducker's post:
https://andrewducker.dreamwidth.org/3652848.html
I've put a modified version of my comment from his post here, so that I can find it again for further thought.
http://advances.sciencemag.org/content/4/7/eaar8680
They reviewed a broad selection of countries over a 100 year period of the 20th C, and they say: "... tolerance for individual rights predicted 20th century economic growth even better than secularization."
Secularization precedes economic development, and so it isn't increased prosperity that causes reduced religious adherence.
Increased regard for individual rights precedes economic prosperity.
I found this link through Andrew Ducker's post:
https://andrewducker.dreamwidth.org/3652848.html
I've put a modified version of my comment from his post here, so that I can find it again for further thought.