https://supreme.justia.com/cases/federal/us/197/11/
> Harlan ruled that the vaccination law did not violate the 14th Amendment because the police power of the state may be allowed to constrain individual liberties through reasonable regulations when required to protect public safety. He reasoned that individual liberty does not allow people to take actions regardless of the harm that they could cause to others. Harlan felt that the plaintiff had failed to show that the vaccination law was arbitrary or oppressive, or not reasonably required for the safety of the public. He noted the increasing presence of smallpox, which prevented the plaintiff from convincingly asserting that the rule had no real or substantial relation to protecting public health and safety. Although the plaintiff presented evidence that some doctors believed that the smallpox vaccine was not effective and could cause further diseases, Harlan pointed out that the opposite view represents the common medical belief and is followed by more reputable doctors.
Not the same thing at all. And you also don't want to go down that road.
EDIT: Getting downvoted so here's the primary holding. Read it for yourself.
> A state may enact a compulsory vaccination law, since the legislature has the discretion to decide whether vaccination is the best way to prevent smallpox and protect public health. The legislature may exempt children from the law without violating the equal protection rights of adults if the law applies equally among adults.
Take drunk driving, for example. We don't give people the freedom to do that. On the other hand, we do allow people to smoke and to eat unhealthily, both of which impose costs on the rest of us. So there seems to be a balance - we allow some behavior that impacts our personal freedoms, but not egregious impacts.
So: If someone doesn't get vaccinated, how bad is the impact to you? Given that vaccinated (and boosted) people can still get infected and spread the infection, how bad is the impact to your personal freedom to live a healthy and free life if someone doesn't get vaccinated?
Vaccines reduce transmission. They do not eliminate transmission completely.