They make something like 200 million iPhones per year.
If you think that can be moved "just fine" then we will have to agree to disagree.
Producing something of the iPhone's quality, at the scale of a half million per day, every single day (that's 23,000 per hour, every hour, 24/7, for an entire year) is not something one can just pick up and move, even with Apple's resources.
It would take several years, if indeed it is possible at all. There are dozens or hundreds of managing workers at Foxconn who have been designing and producing iPhone manufacturing lines for a decade+, and I doubt China would give them and their families all exit visas to move to some other country to assist Foxconn and Apple in divesting themselves of the CCP's prerogatives.
This ain't Factorio.
Then let's agree to disagree, as Samsung, with it's 253 million shipments[1] does exactly that having explicitly moved out of China[2]. It is not impossible.
[1]: https://en.wikipedia.org/wiki/List_of_best-selling_mobile_ph... [2]: https://www.reuters.com/article/us-samsung-elec-china/samsun...
If something has potential, then it will happen. The higher the potential, the faster it will happen. And laws, contrary to what many believe, only has limited potential.
So if leaving China has potential, then it will happen. Tariffs have already made the potential higher, but unfortunately it doesn't seem like it's breaking even just yet.