Ironically you need to be exposed to the strong light outside (as a child), otherwise you will need glasses.
I mean there’s probably a pretty strong correlation between being outside and having a long focal distance, but my understanding was that when attempting to control for this (ie rise of increase in apartment living, first in Japan and then other Asian cities) its tightly correlated to not focusing on things a long way away