Keynesian economics has another half to that story. As well as investing through recessions (which is indeed a good idea), you also have to build a surplus whilst the economy is performing well. That surplus can then be invested through the following recession and so on the cycle goes...