I've heard that the reason why Japan during ww2 had naval giants like the Yamato whereas the Americans did not was because American battleships were limited by the size of the panama canal. Why didn't they just build them on the west coast? Is it because west coast industry wasn't powerful enough?
The US Navy did build ships on the West Coast, and some battleships were constructed at the Mare Island Naval Shipyard near San Francisco.
The Panal Canal restriction wasn't related to the West Coast's lack of industry. It just made strategic sense for a two-ocean navy to have ships that could pass through the canal. That way, the navy could shift ships between the Atlantic and Pacific without having to waste time going all the way around South America.
Japan didn't anticipate a need to use the Panama Canal. Its navy was meant to fight in the Pacific.
As the other response said yes many ships were built on the West Coast, but many of the heavy capitol ships (battleships and carriers) were still from the great shipyards of the North East and Mid Atlantic.
And that was fine and the USN had no problems with it, you point out the Yamato's, and part of the reason they are so crazy is that they were the first ever Post Panamax ships, and thus the only ships afloat during WW2 that couldn't fit through the canal, and the same s true for many years after and it really isn't until the mid 60's when more and more super carriers come on line that it becomes an issue.
Also while the Montanas would have been too big, in 1940 SECNAV Knox approved a plan to expand the locks meaning they would have been able to fit. And just now almost a century later we are finally in the process of actually building new larger locks for the canal.
But on a larger note the USN was ok with being limited by the Canal, as proven by Essex class and Iowa class ships you could have the most effective warships of the time ( compared to the sluggish, over built and bloated Yamato) and still use it. the USN was built upon being an effective 2 ocean navy and that meant being able to rapidly shift forces between coasts as needed.