It's very individual, we all sweat and excrete sodium at different rates. If you're really interested in optimizing your intake, you can wear sweat patches and send them off to a lab, and they'll tell you your sweat rate and electrolyte concentration.
For us nornal people, simple table salt is roughly half sodium and chloride. For potassium, a cheap option is NuSalt, which is a sodium free table salt substitute, it's potassium chloride, and is in your supermarket. Or eat raisins or bananas.
When I'm active outdoors, I find that the 1,000:200 mg ratio of sodium to potassium per liter of fluid staves off cramping. 1,000 mg of sodium is half a teaspoon of table salt, for the 200 mg of potassium, I either use the NuSalt or eat a snack size box of raisins.
The calcium and magnesium found in electrolyte supplements, while important, are not immediately needed like sodium. If you have enough of them in your diet, it's not a concern to add them to a drink.