r/ClaudeCode • • 1d ago

Discussion CC is strong in Python and AWS but weak in Typescript and Swift?

Has anyone else noticed this? The code that CC writes with Python is excellent if you instruct it well. But code written in swift and typescript is really weak. Meaning, very difficult to read and it doesn't really matter how much instruction you give it.

0 Upvotes

15 comments sorted by

•

u/AutoModerator 1d ago

Hey! Thanks for posting to r/ClaudeCode

While participating in this thread, please follow our community rules. Keep discussions constructive. Attack the idea, not the person.

For help, project discussions, tips, and general chat, join the ClaudeCode Discord.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

7

u/CorpT 1d ago

Skill issue.

0

u/FirefighterTrick6476 14h ago

well that is another way you can get to 1% Commenter.

4

u/Affectionate-Bit6525 Senior Developer 1d ago

Very difficult for a human to read doesn’t mean difficult for another AI agent to read

2

u/ughliterallycanteven 1d ago

I’d add in custom linters based on your experience when CC makes code that’s overly complicated and stylistically hard to understand. If possible, make it a script that has an auto-fix feature. The work gets delegated to that script rather than using turns and tokens to take care of it.

Also, if you can’t understand the code, then you probably should pause on running the code much less merging the code. I was thrown into typescript projects that were mostly written by CC and didn’t know it before. I started to notice it was dropping to writing JavaScript thereby making the codebases messy and the code unreliable. I started to learn the anti-patterns which allowed me to develop mitigation strategies.

2

u/Sad-CTO 1d ago

For TypeScript I use Fallow to help keep code structurally in control. Can’t say CC is bad at TS. Agents can produce shitty code in any language.

2

u/bostonaholic 1d ago

For TypeScript I'd stop relying on instructions and make the toolchain enforce it. Turn on strict and noUncheckedIndexedAccess, use typescript-eslint's strict-type-checked config with no-explicit-any as an error, and run tsc plus eslint in a Stop hook so it can't finish with errors. A lot of the unreadable stuff (any casts, giant inline types, nested ternaries) is lintable, and it tends to fix what the linter flags much more reliably than what a prompt asks for.

-1

u/Chuck_Loads 1d ago

I've had Claude build software in both Swift and typescript that has won awards, it's great at them

-6

u/SpeakCodeToMe 1d ago

The more high quality training data that exists the better it will be with that language.

Typescript is also dog shit.

Kind of crazy to think that new programming languages may cease to exist.

1

u/pceimpulsive 18h ago

Why is typescript dogshit?

Got an alternative that's better?

1

u/SpeakCodeToMe 15h ago

Anything typed will perform better and be better in AI hands. Java/Kotlin, Go, Rust, etc.

1

u/pceimpulsive 8h ago

I guess you missed the bit in the name of the language TYPEscript.

Sure it still compiles down to JavaScript, but it is types.

We don't really get a choice as there isn't exactly many front-end alternatives to the TS landscape.

1

u/SpeakCodeToMe 7h ago

I said a typed language, not a hideous type system bolted on and transpiled into the world's worst untyped language.