I've been thinking about #programming languages and types this morning.
Especially about the fallacy of trusting languages like #typescript on the actual shape of the data. I mean all your type annotations and etc still leave you very vulnerable to malformed data / errors during runtime and you end up having to add runtime validation anyways. My current conclusion is that #DesignByContract might be a better avenue for adding input / output verification to a dynamic language like #python or js.
I wonder where we'd be if all the money and time that has gone into typescript had gone into making contracts a viable tool in #javascript
Wikipedia has more info on design-by-contract: https://en.wikipedia.org/wiki/Design_by_contract
Including links to some projects that aim to add contracts to javascript.