The moisture of the refrigerator will eventually turn onions soft and moldy. Keep them in a cool, dry place instead. But don’t put them near your potatoes. When stored together, they both go bad quickly.
Storing coffee beans or grounds in the fridge will make them lose their flavor and even take on the flavor of foods around them. Store large quantities in the freezer, and smaller amounts in a cool, dark place.