As Donald Trump becomes the next president, protectionist sentiments deepen in the United States. Although free trade has meant lower prices and new markets for the U.S. economy, many voters clearly felt those benefits went to CEOs and wealthy investors, not to them. Instead, globalization is blamed for rising inequality and a lack of economic opportunities for many.

Trump’s isolationism challenges long-standing economic and political alliances by repudiating trade deals with key partners and, it seems, by reducing U.S. engagement with the rest of the world economy. The consequences could be far-reaching. At a time of major economic and political realignments in the world, the United States risks alienating its allies and fomenting uncertainty in its relationships with major trading and strategic partners.

In the past, this would have mattered little. As the dominant economic and political power, the United States had no serious economic rival. Now, however, China, the second-largest economy in the world, stands ready and willing to fill any void left by a retracting United States. Already the Chinese government is moving aggressively to strengthen its trade and financial relationships with major economic powers in Asia, Africa, Latin America, and even Europe.

China’s currency, the renminbi (also known as the yuan), is now more widely used in international trade and finance. At the same time, China is increasing its clout in such financial institutions as the International Monetary Fund and the World Bank, and it is setting up such institutions as the Asian Infrastructure Investment Bank, which allows China to rewrite global finance rules. China is also creating alliances with countries that share at least some common interests, such as the BRICS Development Bank that China has set up with other major emerging market economies (Brazil, Russia, India, and South Africa). These tools allow China to bring other countries into its economic embrace.

The results are already becoming apparent. Early on, President Trump signaled his opposition to the Trans Pacific Partnership, a trade deal President Obama painstakingly negotiated with eleven other countries. Though hardly flawless, the agreement would have benefited the United States by requiring its trading partners to accept improved labor, environmental, and intellectual property standards. But now, countries in Asia, including such traditional U.S. allies as Australia, are throwing their lot behind a rival trade deal orchestrated by China that has no such safeguards. In fact, China’s growing influence could end up eroding such important U.S. values as open and transparent government, freedom of expression, and the rule of law.

Of course, China’s dominance should not be overstated. Its economy is still fragile and prone to major volatility. Many countries, including many of its neighbors in Asia, are concerned about its expansionist tendencies. While the renminbi had an impressive rise once China started freeing up cross-border flows of capital, it remains a relatively minor player in global finance.

The United States remains by far the most dynamic, productive, and innovative large economy in the world. The dollar remains the dominant global currency. Despite all its flaws, America’s open and transparent system of government, with institutionalized checks and balances and the rule of law, remains the envy of the world. But the United States cannot count on keeping the world’s trust if it abrogates its leadership role and withdraws from closer engagement with the world economy.

Eswar Prasad is a professor at Cornell’s Dyson School and author of Gaining Currency: The Rise of the Renminbi.