FWIW Apple has had some of the best device support lifetimes of any smartphone. Google started guaranteeing their 7 years of updates sometime around the Pixel 6 or so I want to say.
This is all a relative scale though. But if we're looking at smartphones specifically, I'd argue Apple has been the least force obsolescence of anyone. I wouldn't be surprised if there are some smaller manufacturer niche cases that surpass it.