US president-elect Trump’s anti-Chinese rhetoric is nothing new. For almost 200 years, oftentimes racist resentment of Chinese workers in the US has been a fact of American life.

The first major wave of Chinese immigration began in the 1850s. These immigrants primarily came to work in gold mines and build the railways of the American West. They were not greeted kindly. They were blamed for stealing jobs and driving down wages, and were not welcomed by trade unions. Anti-Chinese groups suggested that these immigrants degraded US morality and were threatening the “integrity of American racial composition.”

US law reflected this Sinophobia. In 1854, the California Supreme Court ruled that Chinese immigrants could not testify against white men in court. The Naturalization of Act of 1870, which established the process for African-Americans to gain citizenship, was excluded the enfranchisement of Chinese laborers. Anti-Chinese feeling in this period often became violent. The worst example was the Chinese Massacre of 1871, when 17 Chinese people were killed in Los Angeles by a mob ransacking the city’s Chinatown.

The anti-Chinese sentiment of the mid-1800s culminated in the Chinese Exclusion Act of 1882. The Act was the first federal law to exclude a particular ethnic group from working in the US. The Act was not repealed until 1943.

Former US president Woodrow Wilson echoed the prejudicial sentiments of the time in his History of American People, published in 1902:

“Caucasian laborers could not compete with the Chinese, could not live upon a handful of rice and work for a pittance, and found themselves being steadily crowded out from occupation after occupation by the thrifty, skillful Orientals, who, with their yellow skin and strange, debasing habits of life, seemed to them hardly fellow men at all, but evil spirit, rather.”

Attitudes towards Chinese people in the US eased prior to World War II. Because China was an ally against Japan, it was then important not to alienate Chinese Americans.

But sentiment grew hostile again during the Cold War. In the 1950s, Chinese Americans faced government surveillance out of fear they were Communist sympathizers. In 1956, the Department of Justice conducted a nationwide investigation of Chinese immigration fraud. Chinese Americans were subjected to random stops to be checked for papers, and the records of 20 Chinese American organizations were subpoenaed.

Since Chinese economic liberalization, fears of competition from Chinese labor have extended beyond US borders although China’s economic rise has been a boon for the world economy. Chinese reforms also opened a new market for US firms and the opportunity to import cheap consumer products. Yet those benefits have been recently overshadowed by the loss of US manufacturing jobs and the reduced wages of some American workers.

President-elect Donald Trump tapped into these sentiments, stirring up deep-seated prejudices. “We can’t continue to allow China to rape our country,” Trump said in a campaign speech. In a debate with Hillary Clinton he said, “They’re using our country as a piggy bank to rebuild China. We have to stop our jobs from being stolen from us.”

There are legitimate reasons to be concerned about how trade with China impacts US workers. But given the long history of racism against Chinese people in the US, one ought to be alarmed at the emotion Trump stirs up.