The best option is the buy the most recently released device you can. We understand that some are a lot cheaper and there is a draw to get older devices. We have already been on the iPad mini 5 for about 3 years. It is still going super strong but who knows how much longer that will last. I think a 4 year lifespan for a device is good. That is not 4 years from the time you get it (less good). That is 4 years from the time it is released.
If I were buying something right now I would get the new iPad mini 6 (or equivalent) with the A15 chip. That way you can plan on getting a solid 4 years out of it.