Maybe a darker environment makes it harder to see distant things, and the benefit of a brighter environment is to enable focusing on distant objects, which is presumably possible even for the poor souls confined to a small cage?
From what I have gathered, the leading hypothesis is that bright light induces dopamine production, and dopamine regulates the development of the eye. When these dopamine levels are too low, the eyeball elongates and becomes myopic.