Some thoughts on what type of tank may also help as there are two common types in use. One is lined so that the water never actually stands in the metal, so no corrosion. The other type/brand is somewhat more prone to corrosion, so uses an anode rod as it corrodes and is replaceable rather than the tank corrode.
If your water heater has no anode rod when you pull the plug the smallish concern about the chlorine and tank corrosion is pretty well nill!
But the reason for bypassing the tanks is still a good idea. One is that it takes far less time and bleach to do the job if we don't have to fill the tank. Since the heat is very good at sanitizing the tank we don't have much reason for doing it!
Chlorine at strong concentrations can react with metal like iron and steel but if we think of how long the old metal pipes last with chlorine treated water setting in them 24/7 we can begin to get a different view of the amount of corrosion we are likely to get at a bit stronger level we use to sanitize. Stronger, yes, but for a very short time compared to how long the old steel pipes are exposed!
I agree that keeping the chlorine out of the water heater may be preferred but it is not a big enough hazard to worry about the tank life.
And as an alternate, if it is something you do want to change, there are bypass kits to add to the back of the water heater if it is not prepped with one!
Different types/brands and prices to choose but this might be a handy one to find?
https://www.walmart.com/ip/Camco-RV-...35983/21781705
I would first want to verify that I don't have one and look at what it might take to get to the rear of the heater!