Judging by the insane smog in their major cities, I'd say they have been pretty short-sighted in what is good for their health.
Blowing CO2 etc. into the atmosphere doesn't look bad in your postcard pictures, but actually adds to the climate problem.
Don't conflate the two things, 'covered in smog' doesn't necessarily mean 'worse than my industrial area with clean skies'.
And finally, China is making a ton of money exporting renewable energy technology. So China is acting very much in its self-interest.