Even the earliest analog sticks like the N64 (Which used LEDs for tracking) didn't suffer from drift — although it did wear out considerably mechanically!
I just bit the bullet and replaced my Joycon's sticks with 3rd party hall-sensing ones, which have worked great so far.
If you find your controller is drifting, then the console just needs some menu where you put the stick to a bunch of reference locations, and then the stick maps outs its own response and renormalizes. "This is neutral." "This is upper-left as far as it goes." "This is..." ect... Maybe even with fine grain mapping adjust if the player really wants control over drifting behavior.
You set high sensitivity and the cursor moves with hand off the controller in a certain direction. You adjust the counter-drift until the cursor doesn't move at all.
You see users of all the consoles anecdotally reporting drift problems. I haven't experienced personally any drift on my PS4 or PS5 controllers, nor an Xbox controller used for a PC. I did have it happen pretty significantly on a Switch Lite.
I also think there's probably an aspect of personal usage patterns: maybe if you're just going through sticks constantly, you apply more pressure, or just use them more, or have something like a dusty environment wearing them out faster.