

That is one reason to do tariffs. However, as someone who’s consulted in a variety of industries, it’s stupid to do non-targeted tariffs like this. There’s no way this is going to rebuild industry on shore in the US, exactly as you say. That takes years or decades to even build up an infrastructure and a supply chain, not to mention that, at least recently, we’ve had low unemployment rates and no one to work the jobs anyway.
The CHIPS act was a better way to do it. If you believe you need to re-onshore an industry, then give multiple years’ warning before implementing tariffs and provide support for redeploying domestic production capacity. However, for some strange reason, the Republicans don’t like that act.
It can also be EXTREMELY long code to do something relatively simple. I bounce between base and ggplot, and use ggh4x for some oddly difficult stuff in ggplot.