From Nokia 808 to Pixel 2: phone cameras got drastically better with time
While the camera testers' methods and ranking scheme have been a subject of criticism and scrutiny by shutterbugs, DxOMark has been probing digital cameras and lenses for many years, making a name for themselves, and, about 6 years ago, they started running cell phone cameras through the paces, too.
The shop just came out with a breakdown of their quality ratings on a 100-scale during that time, and it turns out that from the first major cameraphone they tested - the Nokia 808 PureView - and the current cream of the crop like the Pixel 2, iPhone X, Mate 10 Pro, or Note 8, there has been a drastic improvement, despite that the phones have gotten thinner, and the sensor sizes are still quite small.
The megapixel war was over a few years ago, and manufacturers focused on pixel sizes, focusing technologies, and improving software algorithms. One can see very clearly what a difference this had made to the cameras we always carry in our pockets, in the span of just a few short years.