If you use salt you will get H and Cl I think.
Using NaCl certainly would not be a preferred path. What you make will depend on the concentration of the salt, NaCl, and the pH of the solution. Usually if you electrolyze aka line salt water you end up with bleach, NaOCl. This a safe, effective alternative method to kill microorganisms in water and sewerage instead of chlorination. I believe that under certain electrode conditions you can get NaOCl to decompose into oxygen, O2 according to the equation 2 NaOCl ==> O2 + 2 NaCl. Other concentrations and pHs can yield hydrogen chloride, HCl or chllorine, Cl2 as well.
A fairly comprehensive summary of the electrolysis products can be found here.
https://en.wikipedia.org/wiki/Electrolysis_of_water
A "New Age" cure-all industry has grown around the electrolysis of salt water. In various electrochemical cell configurations you can generate hypochlorous acid, HOCl, in one half cell and sodium hydroxide, NaOH, in the other half cell. When you mix the two solutions together you get NaOH + HOCl ==> NaOCl + H2O which is what you make in a cell without the membrane!
https://www.aquatechnology.net/electrolyzed.html
https://boingboing.net/2009/02/23/electrolyzed-water-a.html
Other articles in the wiki reference suggest using sulphuric acid, H2SO4 (battery acid) as the electrolyte.
https://www2.uni-siegen.de/~pci/versuche/english/v21-2.html As sulphuric acid is not user friendly, the sodium salt of the acid, sodium sulfate, Na2SO4 can be used as the electrolyte.
https://chemmovies.unl.edu/Chemistry/DoChem/DoChem044.html
Sodium sulfate is a very cheap material, and the largest use is as filler in powdered home laundry
detergents, consuming approx. 50% of world production so this might be an attractive source of the material as well.
https://en.wikipedia.org/wiki/Sodium_sulfate
Bob