Yeah, if you travel enough, you will get sick sometime. To be honest, with being packed in with other people, exposed to new strains of bugs, different bacterial mixes, viruses, all complicated by the stress and effort of travel, I am surprised we do not get sick more often.
But you have to have the attitude to roll with the punches, if you feel a bit under the weather, feel yourself going down, then decide to have a "down" day, taking it easy (and hopefully away from others), maybe time in a park, in the Sun, or just holed up in your room. Maybe send a partner out to get some fruit, hydrating drinks, or whatever sounds good. Sometimes "nipping it in the bud", some self-care and rest, is wiser than soldiering on and being down and out for days later.
We also carry basic meds, Ibuprofen, allergy meds, for me, Mucinex DM has worked wonders, maybe some gastro meds. We do not bring a bunch, just enough until we can get to a pharmacy, or stuff not easily available there.
Speaking of Pharmacies, they are a great resource when traveling. Pharmacists can listen to your symptoms (most speak very good English) and suggest something to help, including the odd item that may be "prescription only" here in the US.
If seriously ill, do not hesitate to head to a Doctor. Your hotel or a pharmacy will know one, most are excellent Doctors, and the cost will be way less than what you experience here in the US (think tens of Dollars, not hundreds).