Marvel distinguished itself from other publishers by using "the world outside your window" as the setting for its stories and home of its characters.
For Spider-Man, this was New York. The New York skyline, with its skyscrapers and famous landmarks, made the perfect backdrop for a superhero who could swing from webs and climb walls.
Amazing Spider-Man Volume 4, #1 (2015) expanded the scenery beyond the iconic New York setting of so many Spider-Man stories to include a number of locations in America and the world. The most prominent among these was Shanghai, China. As head of Parker Industries, Peter Parker chose Shanghai as the location for the headquarters of the Asia branch of his company, and the launch of his Webware technology. He also learned Mandarin, and used it proficiently with company employees and the general public as both Peter and Spider-Man.
Many Spider-Man adventures took place in Shanghai, including smashing a drug ring run by Mr. Negative, and a dramatic confrontation with Doctor Octopus on the city's buildings which resulted in the collapse of Parker Industries.
But why China? And what were Peter's reasons for learning Mandarin?
China's growing importance in the world, not just as an economic and political power, but also as a cultural and scientific power, has given it an ever-expanding place in the global consciousness, for reasons positive and negative. Shanghai epitomizes the modern, high-tech face of China, and was therefore a suitable backdrop for this chapter in Spider-Man's history.
Likewise, languages become desirable to learn when they are associated with powerful countries and people. Peter's acquisition of Mandarin was by no means unique - approximately 100 million people worldwide are learning Mandarin as a second/additional language. This phenomenon is often called Chinese Fever (汉语热), and is propelled by China’s rise.
Story events (and another reboot) returned Amazing Spider-Man to New York, and neither Peter nor Spider-Man have spoken Mandarin since. Hopefully the creative team will not forget about their character’s linguistic repertoire, because the ability to speak Mandarin deserves as much attention as Spider-Man’s other powers.