(no title)
dsQTbR7Y5mRHnZv | 2 years ago
Whether you specify them or not, the data moving around your application _has_ types.
Strings, ints, booleans - they're all there. You're just keeping that information in your head while you work.
By writing them in the code, you're simply offloading all of that and saying "I trust the computer to validate this better than I can." Which is exactly the kind of thing we should be trusting computers to do. They won't forget what type something is 5 function calls deep and they won't get tired from lack of sleep.
I know I prefer having the computer tell me I made a mistake while I'm developing something rather than a user emailing me after I've shipped it.
irrational|2 years ago