Closed kevinclarkadstech closed 1 year ago
If strong typing were built into the programming language itself, this would be understandable. However, when typing only pretends to be strong and then compiles into a typeless language, it is a crutch and just another abstraction that ends up being untyped code.
Simply put, this is the replacement of a real process with a fiction.
I'm not against typing, but isn't it easier to write in a language that was typed to begin with? Then both the wolves (typing) and the sheep (speed) will be happy, instead of the sheep pretending to be wolves. Adult programming languages only need typing to help the compiler produce fast code so that it makes optimal use of resources and allocates the right size memory. In JavaScript, typing has become a kind of cult or sect that turns it into absolute documentation and discards optimization.
Convinced that people that don't like type safety are just bad programmers.
Convinced that people that don't like type safety are just bad programmers.
on david
Today I heard someone mention that TypeScript was being removed.
I don't think the view of "can't learn it in 5 minutes, won't learn it in 5 years" is correct. What I'm about to elaborate on has nothing to do with religious or ideological beliefs regarding technology, but rather describes this from the perspective of developer creativity.
In my career, I've led many teams, including C++, .NET, Java, and of course web teams.
I've carefully observed these web teams I've led and summarized a pattern: developers who choose to avoid TS due to a certain learning curve, what they actually fear is not just the cognitive cost of the language itself, but rather the cost of learning anything new. As a result, they reject having to think about anything, and even dealing with moderately complex matters using programming logic makes them seem lacking in initiative. Other than templatized UI drawing, they reject everything, doing work every day that could easily be replaced by AI. However, developers who don't mind the learning curve of TS itself, are generally willing to think about any other problem, like algorithms. They can proactively use programming logic to solve relatively complex problems, and overcome the "selfishness" of human nature through teamwork, figuring out ways to reduce the comprehension burden on others. Giving an active, upbeat impression.
This is not a manager's beliefs or biases, but actual observations from work. Of course, this may be related to the city and country I'm located in, and not the case elsewhere. But these are my observations. Therefore, in interviews I consistently reject applicants with a "can't learn in 5 minutes, won't learn in 5 years" mentality.
Additionally, we can't use ordinary examples to evaluate how TS/JS should be chosen. Much of the time, the value of a more advanced language needs to be considered in more creative scenarios. For example, please look at the GIF animation of this graphql client, it brings tremendous convenience and development experience for developers, far beyond what JS+Docs can offer.
If strong typing were built into the programming language itself, this would be understandable. However, when typing only pretends to be strong and then compiles into a typeless language, it is a crutch and just another abstraction that ends up being untyped code.
Simply put, this is the replacement of a real process with a fiction.
I'm not against typing, but isn't it easier to write in a language that was typed to begin with? Then both the wolves (typing) and the sheep (speed) will be happy, instead of the sheep pretending to be wolves. Adult programming languages only need typing to help the compiler produce fast code so that it makes optimal use of resources and allocates the right size memory. In JavaScript, typing has become a kind of cult or sect that turns it into absolute documentation and discards optimization.
I see your argument. The thing is, I can't write in a language that has typing to begin with if I want to program for the web. JavaScript is de facto. Yes, with very disciplined comments and documentation it could be fine to program in, but if you've ever worked on a large project with deadlines, you know that never happens. Having to run code and console log an object because of this becomes a nightmare. TypeScript is self documenting so it helps prevent the problem of lazy coders not commenting and documenting their JavaScript. This day and age, any library should at least offer typings, even if it is not written in TypeScript, if it wants user adoption. ESPECIALLY if it is a lib on a paid project. The point is removing TS from the core code will probably discourage contributions, and they may be fine with that, but not offering types (plus the nature of the removal) will discourage consumers.
If strong typing were built into the programming language itself, this would be understandable. However, when typing only pretends to be strong and then compiles into a typeless language, it is a crutch and just another abstraction that ends up being untyped code.
Simply put, this is the replacement of a real process with a fiction.
I'm not against typing, but isn't it easier to write in a language that was typed to begin with? Then both the wolves (typing) and the sheep (speed) will be happy, instead of the sheep pretending to be wolves. Adult programming languages only need typing to help the compiler produce fast code so that it makes optimal use of resources and allocates the right size memory. In JavaScript, typing has become a kind of cult or sect that turns it into absolute documentation and discards optimization.
If TypeScript shouldn't be used since it is "a crutch" and "a replacement of a real process with a fiction" should we stop unit testing (I'm just drawing a comparison, I support unit testing)? Unit testing is fiction and a replacement in the same way types are.
I see nothing wrong with removing TypeScript from the codebase, but not including Types for your users shows you do not care about them. Nobody has any problem with HTMX or Svelte being written in JavaScript because they still provide types for their users.
@kevinclarkadstech how does it affect you and your work? You don't even use Turbo. Therefore, your opinion on this question does not matter.
TypeScript is a superset of JavaScript that can provide static typing. This will make it easier for contributors and consumers of the codebase.