We have some 12 year old LGs that are still going strong, get used every day.
First thing to do is drill a couple holes so that when water gets on the folded up gate it doesn't pool up in the framing on the underside of the deck. If it drains off the rust damage to the deck is minimized.
2nd, when rust does form, or paint goes missing, use POR15 (we do this every 2-3 years) and then apply a topcoat of a protective enamel when the POR15 is still tacky. this lasts a long time in the spots you do it. the paint only sticks to rust so we only do it where the factory paint is already off and rusting.
3rd. every couple weeks we lube all the points with white lithium grease, and then when we wash the truck, use a powerwasher to clear all the old grease/dirt/mess out of the joints, then relube. if you keep them well lubed, those pivots and pins last a LONG time.
All of ours are steel though I do covet those nice large-deck aluminum ones, it's about $10K to have one added I think.