It's really not that complicated. The government banned people from trading causing extreme poverty and famine in one of the most fertile areas in the world. Then they reversed the ban and let Chinese people trade again. At the same time western companies setup factories in China causing massive capital inflows.
If it's really as simple as allowing trade with the west then why are many other developing countries either stuck at the middle-income trap or not developing quite as fast as China? You're not gonna tell me Chinese are smarter, are you?