Whooping cough, also known as pertussis, is still around, and it's extremely dangerous, especially for babies. It's easily prevented by the DTap vaccine, but kids don't get that until they're 2 months old. Until then, it's important for caregivers to be immunized. But can breastfeeding moms get vaccinated for whooping cough? In a word, yes. Anyone who's in close physical contact with an unvaccinated baby should get the Tdap vaccine so that they don't pass pertussis on to the child, and getting it while you're breastfeeding is perfectly safe for both the mother and the baby.
The Centers for Disease Control has recently published new guidelines for adult vaccinations, but its position on breastfeeding mothers remains the same: "Neither inactivated nor live vaccines administered to a lactating woman affect the safety of breastfeeding for mothers or infants. Breastfeeding does not adversely affect immunization and is not a contraindication for any vaccine." Additionally, the report stresses, "Although live vaccines multiply within the mother's body, the majority have not been demonstrated to be excreted in human milk." Therefore, it most likely won't protect your baby from catching whooping cough from someone else, so contact with the general public should be limited until they're old enough to receive their own vaccination.
Generally, adults should receive one dose of the Tdap vaccine, which protects against tetanus, diphtheria, and pertussis, as well as additional Td (tetanus and diphtheria) boosters every 10 years. Unfortunately, many don't. The overwhelming majority of pertussis cases occur in babies under 2 months of age, most of whom catch it from their family members. For this reason, the CDC originally instructed families to get vaccinated immediately after a baby's birth. The recommendation was later changed, and pregnant women who had never been vaccinated were advised to get the Tdap shot during pregnancy, preferably after 20 weeks.
The guidelines were last changed in 2013, and the current recommendation is that all pregnant women, regardless of past immunization history, get the Tdap vaccine during each pregnancy. That's because when Tdap is administered during the third trimester, some of the antibodies will be passed on to the fetus, giving the baby some extra protection during those first two months of life. It does take time to develop the antibodies, so it's best to get vaccinated earlier in the third trimester rather than later. Mothers who get Tdap after the baby is born are cautioned that it takes about two weeks to develop immunity, so maybe hole up on the couch for a while. Honestly, you'll probably be too tired to face the world, anyway.