The first journal purely dedicated to science was the Paris-based Journal des sçavans, founded in January 1665. The London-based Philosophical Transactions of the Royal Society was founded two months later. The Journal des sçavans appears to have died a fairly quiet death in 2007. But the Philosophical Transactions is still around, is still prestigious, and still publishes papers in pretty much the same way as it has done for centuries. I published a paper there myself not too long ago.
When these journals were founded, they provided an excellent platform for scientists to share their work. Science was mostly a regional affair, and very few people were wealthy enough to engage in the leisure of science. And, of course, there was no internet. In this small analog world, papers were the best form of communication.
Things change, though.
Some time ago I wrote about a dataset that I had downloaded from PubMed, which is a more-or-less comprehensive database of scientific articles. I downloaded information about only 38 journals, but even from this small selection it is clear that papers are being published at an exponentially increasing rate, and that this trend has been going on for some time.