This story was originally published on May 31, 2019. It has been updated to reflect President Donald Trump's threat to invoke the 1977 International Emergency Economic Powers Act in his trade war with China.

(CNN) President Donald Trump is threatening to use his broad executive authority in a new and unprecedented way in his escalating trade war with China, arguing he can order companies to start doing business elsewhere.

"Our great American companies are hereby ordered to immediately start looking for an alternative to China," he tweeted on Friday. He later explained that he was referring to what he called the "national emergency act" of 1977 -- actually, the International Emergency Economic Powers Act.

It's not the first time he's leaned on it. In May, he threatened to slap Mexico with punitive tariffs unless it slowed the passage of migrants from Central America to the US -- and ultimately drew back at the last minute.

But how far can Trump go under the act?

One key thing to know is that the emergency powers he wants to use evolved from the need for the President to act with decisive authority during war, specifically World War I. The Great Depression prompted the expansion of emergency powers to include economic emergencies, according to an analysis by the Congressional Research Service . (This piece uses many facts from that analysis, which is worth reading.)

These powers were used throughout the Cold War until the 1970s, when, according to CRS, Congress basically realized the US had been in a state of emergency for 40 years and put new restrictions on the President, including requirements to track the cost of any emergency and justify it each year.

The law by which Trump can impose sanctions like the tariffs, passed in the wake of Watergate and Vietnam, is the 1977 International Emergency Economic Powers Act. This authority has actually been used quite frequently; there have been 54 national emergencies, 29 of which are ongoing.

Some of these emergencies targeting countries have been going on for decades, like sanctions on Iran. Others, like the one enacted by Bill Clinton targeting narcotics traffickers, have certainly affected people in Mexico , but just as certainly not affected the whole country.

The law has never, before now, been used the way Trump wants to use it, and the CRS said it hadn't been invoked to impose tariffs.

Mexico is a neighbor and ally, from which we bought $345 billion in stuff last year because we are joined together in the North American Free Trade Agreement. That's an incredibly broad application, especially considering those costs would ultimately be passed along to American consumers, who ultimately bear the brunt of tariffs -- which are paid by importers, not by exporting countries.

They'd have affected the supply chain for the US auto industry, machinery, medical instruments, not to mention the avocados and tomatoes in American salads, fruit, vegetables. All of it.

And it's a two-way street. Americans sold just shy of $300 billion in goods to Mexico in 2018 -- cars, machinery, pork and beef. Billions and billions dollars worth of many different type of goods that might be subject to retaliatory tariffs from Mexico.

All of that is even more true of China.

White House officials privately conceded it's not clear the President has the legal authority to impose tariffs on this scale, CNN reported in May. They were concerned that the move could draw legal challenges that could leave it tied up in the courts without ever taking effect.

But Stephen Vladeck, a law professor at the University of Texas and a CNN legal analyst, said what Trump is doing under the law may very well be within the authority Congress gives the White House -- though it's just as surely not what Congress ever intended.

"The idea behind these authorities is that the President is better situated to make those kinds of determinations than Congress, especially when they're time-sensitive," Vladeck said in an email. "So I think the President's conduct may well be within the letter of the law here. But, as with the National Emergencies Act, I very much doubt this kind of exercise of the authority conferred by the statute is what Congress had in mind."