GPT4 vs GPT3.5 for coding? which one is most accurate?

I noticed lately that GPT4 is very inconsistent when it comes to code.
For Node , Next JS, with Type Script.

Then I got auto switched to GPT3.5 and it seemed to do a better job. Just wondering what everyone else thinks? cheers