3 ms·
The trouble with Typescript is that the corporates have gotten their hands all over it as a means of turning JS into Java. TS turns lean, functional JS into an
by cutler 8y ago
The trouble with Typescript is that the corporates have gotten their hands all over it as a means of turning JS into Java. TS turns lean, functional JS into an over-engineered smorgasbord of classes, interfaces and general OOP nonsense. JS was designed primarily as a functional language.
- pault 8y agoThis runs counter to my experience. I've found that TS will confirm to any style of programming you prefer to use. If you want to avoid classes and inheritance, just type your functions and data structures and call it a day.
- dboreham 8y ago>lean, functional JS into an over-engineered smorgasbord of classes, interfaces and general OOP nonsense Aka "code that someone other than you can understand"
- Gene_Parmesan 8y agoRight, because functional languages aren't known for having highly expressive type systems at all. And anyways, while Eich's original dream was to bring Scheme into the browser, it's obvious that forces at Sun, by telling him to make it more similar to Java, changed the nature of the language in a core way. It's absurd to say JS was designed primarily as a functional language when there is mutation everywhere, inconsistent use of equivalence, and one of the looser type systems still in existence. Either way, I'm surprised that that's been your experience, because I have found it to be the opposite. I've found TS to be most of what I like about C#'s typing (interfaces are an incredible, foundational tool) with much less of the ceremony. I still prefer C#, but I find TypeScript's flavor of OOP to be one of the lightest (in terms of enterprise-OOP, langs like Smalltalk obviously still take the overall cake).
- BrendanEich 8y agoHi, just for the record, Netscape management as well as Sun insisted that JS look like Java. Java was supposed to be the big language on the client side. That didn't pan out, but JS got big and begat WebAssembly thanks in part to the asmjs.org latent static type system (another part: WebGL typed arrays).