Smallpox was wiped out by using mathematical containment rings coupled with vaccines and it makes sense that one way to contain an infectious disease outbreak is to limit travel.
Unless travel bans are only bans for some people. In communist China, elites are still going on vacation, they are still traveling for business, they are still going to foreign colleges. The novel coronavirus in Wuhan, China, now known as COVID-19, has infected tens of thousands and killing hundreds while spreading to at least 24 other countries. That led many governments, including the United States, to restrict travel to and from China.