TypeScript: It’s not about dynamic vs. static
I have to say I actually like TypeScript as an idea. The idea of type safety and static type checking as an optional compile feature in a language is pretty amazing. That means I can use the types when I need to enforce a hard boundary and still use dynamic programming to get all the benefits that it offers. But that doesn’t matter as much. For me it’s about discover-ability and growth.
Slow developer growth
Static languages (Java, C#, etc) tend to focus on the interfaces and what the IDE can tell you via Intellisense. Your class, method, or property has to have enough type information to tell the client developer how it should be used and how things work. By it’s nature it’s an authoritarian method of information dispersal. Your static code tells the client they need to pass in this type of object (string or int maybe) and you will process it. The client developer doesn’t know how it is implemented or what you going to do with it. Since the IDE is the major source of information for the developer it shouldn’t be a surprise that the C# or Java developer tends to be IDE-dependent and in many cases is stereotyped as being less “clever” than their dynamic programming counterparts. The inability and even the reduction in need in most cases to dig into the source and see what is going on slows the client developers growth. They don’t get to learn from your amazing library. Opensource can help to mitigate this but many companies that use static languages also tend to have a poor policy when it comes to opensource.
Rapid developer growth
Pick your poison
This isn’t meant to incite an us versus them or a decry static programming as evil. There are not so flattering stereotypes of programmers in both static and dynamic languages and there is a grain of truth to them. They both have their place and if you think you are a great /(static|dynamic)/ programmer but you haven’t tried the other then you are missing out. You could be a static programmer with a dynamic programmer’s inquisitive barrier-less mindset. Or you could be a dynamic programmer with an ability to scale large codebases in a clean, modular, and error-free way.
There is no one true way. There are many paths to but you need to be open to them. Become the programming equivalent of the martial arts quote by Bruce Lee “Don’t get set into one form, adapt it and build your own, and let it grow, be like water. Empty your mind, be formless, shapeless — like water. Now you put water in a cup, it becomes the cup; You put water into a bottle it becomes the bottle; You put it in a teapot it becomes the teapot. Now water can flow or it can crash. Be water, my friend.” http://en.wikiquote.org/wiki/Bruce_Lee