IMHO, I think the better way for China to handle this Nancy Pelocy's visit is through economic sanctions/warnings on Taiwan companies in Mainland who fund this trip, dump some US treasuries, cause US to suffer much more economic pain like putting more export tariff, etc.
Hot war should be avoided for now because sooner or later, I think Taiwan will merge with Mainland. Beside that, they are all Chinese people too. I think with this response, China might look like lose to Pelosi but actually winning by gaining sympathy of people in Taiwan because they will think that the CPC leaders prioritize ordinary people lives and don't want to hurt ordinary people in Taiwan but hurt those people who instigate the conflicts. The purpose of the goal is to reunite Taiwan with Mainland without hurting ordinary innocent people on both sides.
And then hopefully more and more people in Taiwan will realize and feel disgusted with those traitors who collaborate with outsiders to cause war and suffering to people in Mainland and Taiwan. In the next Taiwan election (midterm in November 2022 and full term in 2024), hopefully there will be friendly leaders who will have same vision with the leaders in Mainland.