I've noticed that certain LEGO colors have a tendency to turn yellow over time. For example, I have a set of 4 "white" wheel hubs that are all now various shades of yellow:
I know there is already some information on how to fix this, but I'd like to understand why this happened and how to avoid it. What causes LEGO parts to turn yellow, and what specific steps can be taken to prevent this damage?