3 ms·
"Typing everything allows you to clearly and succinctly declare intentions with your code as well as enforce those intentions throughout your code base. For an
by jacknews 2y ago
"Typing everything allows you to clearly and succinctly declare intentions with your code as well as enforce those intentions throughout your code base. For an application with many developers, being able to clearly and definitively express what code does is a huge advantage over code that requires a fellow developer to spend cognitive energy to figure that out."
Types are definitely useful in the fight to 'make invalid states impossible', but this rather overstates the case. They go only a very little way in documenting intent.