The much better cameras help a lot, I guess. I remember scanning QR codes with a 2014 and a 2018 (yeah, already old) flagship phone and being amazed at the distance the latter was able to do it from. At least 3x the distance from the QR code vs the old model, and the autofocus was near instant, too.