3 ms·
I don't get this. What do you mean by coffeescript vibes? They are super different languages...
by sanderjd 6y ago
I don't get this. What do you mean by coffeescript vibes? They are super different languages...
- heavyset_go 6y agoIn that JavaScript only needs to adopt a few of its features for the benefits of welding yet another compiles-to-JS toolchain on to projects to dwindle in comparison to writing ES8+.
- Vinnl 6y agoThe difference between CoffeeScript and TypeScript was that CoffeeScript offered syntax that people preferred, whereas TypeScript provides write-time checking of errors. It is more similar to ESLint in that regard, and is better understood as a linter than as a separate language like CoffeeScript. Even if TS's type annotations would be added to the language (like it practically almost has been, through Babel supporting it), you'd still want to run a tool as you write it to actually check that those annotations are adhered to, rather than having your code crash on the user when they are not. TypeScript is that tool.
- z3t4 6y agoAdding optional type annotations to JS would be interesting. It might help with VM optimization.
- heavyset_go 6y agoPython already does type annotations, and I have no use for Mypy other than using it for type checking in my editors via LSP. I don't import it or use it as a dependency at all in projects. I feel like JavaScript adopting type annotations in a similar manner will make TypeScript look the same as Mypy in many regards: nice to have, but not necessary most of the time because the parent language ships with most of its features.