This was an issue in the computer science field well before LLMs, though (like in many areas) they did pour gas on the fire.
TBH I think it’s more of an issue for paid software. Manpower and burnout is the bottleneck for FOSS projects, and contributions are largely thankless, hence I think amongst the people who do contribute, there will be more of an interest in truly learning the codebase.