To keep your Nintendo 64 joystick in good shape, the best approach is a proper lubricant rather than a household spray. A silicone-based lube, the kind popular in airsoft guns, works very well for keeping the mechanism smooth.
Some people even suggest something like KY jelly as an alternative. Whatever you choose, the key is a lubricant that reduces friction without degrading the plastic.
One important warning: avoid WD-40 entirely. Over time it will ruin the controller, so steer clear of it despite its reputation as a fix-all.