Markets around the world plunged Friday morning as the shock of Britain’s vote to leave the European Union ripped through the global economy.

Donald Trump, for his part, aligned himself firmly on the side of the economic chaos. In the long term, if the Brexit vote triggers a slowdown or sustained job losses in the United Kingdom -- as many predict -- Trump may find that he's made a fatal error.

The presumptive GOP presidential nominee bragged on Friday that his ideas are well-reflected in the sentiment driving the Brexit: a feeling among the English that they needed to “reclaim” their country from immigrants (particularly Muslims) and globalization.

“I felt it was going to happen,” Trump said Friday at a press conference held on his golf course in Scotland. “There are great similarities between what happened here and my campaign. People want to take their country back.”

Just arrived in Scotland. Place is going wild over the vote. They took their country back, just like we will take America back. No games! — Donald J. Trump (@realDonaldTrump) June 24, 2016

If the Brexit continues to roil markets, those words could come back to haunt Trump. The vote across the pond could serve us a perfect case study for the reality-TV star’s ideas, which include deporting millions of people and banning an entire religious group from coming to the United States. These nakedly racist and nativist policies, plus the call to “make America great again,” are the American equivalent of the anti-immigration mood that drove English voters to turn against Europe.

There was even a Trump-like character, Nigel Farage, leading the movement to leave the EU, as The Huffington Post's Marina Fang noted. A businessman-turned-politician, Farage heads the right-wing U.K. Independence party and has called Muslims a “fifth column living within our country, who hate us and want to kill us.”

On Friday, Trump doubled down on the similarities, speaking at a press conference in Scotland.

“I really do see a parallel between what’s happening in the United States and what’s happening here. People want to see borders. They don’t necessarily want people [coming] into their country they don’t know where they’re coming from,” he reportedly said.

Trump also boasted that he’d profit as the British pound declined in value.

So far that sentiment has sent stock markets plunging, wiping out $2 trillion in value from capital markets on Friday, and potentially set us up for a summer of economic turmoil.

The specter of job loss hangs ominously over the U.K., particularly for 2.2 million financial workers in the country. Before the historic vote on Thursday, employers signaled that they’d flee the country if it voted itself out of the Union. In April, John Cryan, the British-born chief executive of the German giant Deutsche Bank said he planned to move operations to Frankfurt, Germany’s financial capital.

Goldman Sachs, which has warned for years that leaving the EU could devastate the British financial sector, seems likely to move to Germany, too. JPMorgan Chase chief Jamie Dimon, who threatened to quit the U.K. if it left the EU, said in a memo to staff Friday that “we may need to make changes to our European legal entity structure and the location of some roles.”

HRC campaign needs to put together ads w/comments from "leave" voters, saying they didn't think their votes would matter, weren't informed. — maria lia calvo (@MariaLiaCalvo) June 24, 2016

Brexit could spell trouble for the British tech industry, too. Startups benefit from European laws designed to create a “digital single market” worth an estimated €415 billion, or about $460.8 billion.

“This could be a new Lehman moment,” one investment manager overseas told The Wall Street Journal, referring to the collapse of the investment bank in 2008 that set off the financial crisis.

“Today’s UK referendum results on European Union (EU) membership will mean more uncertainty for businesses around the world as they navigate the complex implications," Mark Weinberger, global chairman and CEO of consulting firm EY, said in a statement.

To be sure, already on Friday, political leaders were working to quell the chaos. Martin Schulz, president of the EU parliament, told The Guardian that EU lawyers would work to hasten the Brexit -- which could take up to two years of negotiation -- in hopes of minimizing volatility in the market.

In the U.S., President Barack Obama reassured the world that America and England are still friends. "The people of the United Kingdom have spoken, and we respect their decision," Obama said in a statement. "The special relationship between the United States and the United Kingdom is enduring."

Still the road ahead looks pretty rough. And definitely in the short term, Trump’s ideas just got a big test overseas and they failed -- here’s hoping Americans are paying attention.

Editor’s note: Donald Trump regularly incites political violence and is a serial liar, rampant xenophobe, racist, misogynist and birther who has repeatedly pledged to ban all Muslims — 1.6 billion members of an entire religion — from entering the U.S.