The Taiwan Strait is extremely efficient for shipping routes. The sea and wind to the East of Taiwan are treacherous. Going the long way round would be very difficult and greatly increase shipping costs for a substantial portion of the world's goods.
This is not an issue at all because the current rules permit peaceful passage through territorial waters. That broadly means no lingering, no spying, and going straight to the intended destination. Access can be denied for security reasons of course.
This is totally fine for commercial traffic. Since China has a huge export market, it is also not interested in raising shipping costs.