At the outset of humanities recorded history, there was a sense of community and clan. This was due primarily to the need for survival. When the community shifted from a hunter/gather paradigm to an agrarian society, the reason was work sharing. Agrarian societies also gave rise to larger families for much the same reason. Early religions grew up around this idea of these large families and community setting because of not only the work requirements but the developing human’s need for a sense of belonging and community.
During the middle part of the 20th century, the world as a whole (except for rural extended families) saw a rise in the “nuclear family” of two parents and two kids. This changed the face of the community, effectively severing many of the long-term ties between families. This shift also occurred in religions where theology and doctrine began to be more focused on the concept of personal salvation. Good works were still being done but instead of a community-based approach, it became personal responsibility.
Over the last few decades, with the advent of an information society where groups can stay in contact almost instantly a rise of social responsibility, extended community, and fictive kin has been on the rise. Community groups and even tribal-similar groups have begun to show in similar ways. This includes basic ideas such as resource sharing and communal living. Once the province of fringe living and the 60s and 70s counter culture, this has now began to creep into the mainstream.
Religion and spirituality have begun to see the same shift, especially in the direction of community as a religious entity. Progressive spirituality, engaged spirituality, Liberation Theology all point towards a socially conscious view of religion where the spiritual leaders in the community are also active in social programs. How this will eventually evolve has been speculated on but as with anything else, opinions vary.