Sure, discipline can prevent some errors. But it’s always possible to run into wrong type assumptions, and I’d say type coercion and null/undefined access make up a fairly large percentage of non-logic errors. You can entirely prevent those using Typescript, which is why it’s so useful.
Static type analysis is always a good idea if you’re writing more than a couple lines. IMO Python is the worst offender with its kwargs etc. - discoverability and testability is just so bad if you’re following common Python idioms.
Sure, discipline can prevent some errors. But it’s always possible to run into wrong type assumptions, and I’d say type coercion and null/undefined access make up a fairly large percentage of non-logic errors. You can entirely prevent those using Typescript, which is why it’s so useful.
Static type analysis is always a good idea if you’re writing more than a couple lines. IMO Python is the worst offender with its
kwargs
etc. - discoverability and testability is just so bad if you’re following common Python idioms.