LOS ANGELES • Long before United States President Donald Trump acted to block arrivals from the Middle East and Africa, an 1882 law banned workers from China and ended naturalisation for Chinese nationals.
The move severely complicated life for more than 100,000 ethnic Chinese already in the US, many recruited to build a transcontinental railroad.
This period of US history is explored in The Chinese Exclusion Act, a new PBS documentary debuting on May 29 from Emmy-winning film-makers Ric Burns and Li-Shin Yu. "This is not simply an immigration story, it is the American immigration story," Burns said.
Said executive producer Stephen Gong: "In the process of resisting the discriminatory laws, the Chinese community helped define, in the most positive ways, what American citizenship is."
In the 1840s, Chinese workers were drawn to California by the Gold Rush. Eventually, the mines began to dry up and they became targets for reprisals by white miners whose resentments were inflamed by local politicians.
The transcontinental railroad, completed in 1869, brought cheap labour east and racism against the Chinese spread, fanned by the economic crash of the 1870s.
"We have today to decide whether we shall have on the Pacific coast of the United States the kingdom of Christ or the kingdom of Confucius," then senator James Blaine told fellow legislators.
The Chinese Exclusion Act was passed and racist purges multiplied catastrophically as 300 towns from Wyoming to Oregon turned against Chinese-American inhabitants.
The authorities prevented Chinese-Americans from returning after visiting loved ones back home and barred them from owning property and businesses.
Activists note that when Congress finally repealed the Act in 1943, the US still let in only 105 Chinese each year and did not open up to large-scale immigration by non-Europeans until a landmark 1965 law championed by then senator Ted Kennedy.
"If there is a word that defines the Chinese-American experience, and Asian-American experience, it's exclusion," University of California, Berkeley professor emeritus Wang Ling-chi told the film-makers.
But the US House of Representatives formally expressed regret for the country's anti-China policies in 2012, eight months after the Senate had passed its own apologetic resolution.