35 ms·
> "TypeScript is better because I'm required to run the transplier" You've missed the point entirely. The whole point is that TypeScript benefits from compile-
by rumanator 7y ago
> "TypeScript is better because I'm required to run the transplier"
You've missed the point entirely. The whole point is that TypeScript benefits from compile-time type checking, which is performed by TypeScript's transpiler.
Python's type annotations are just that: annotations, which can/have no effect.
- takeda 7y agoWhen you have a compiler/transpiler the process typically is done in two steps, running a type checker on the code and then the actual compilation (which could be split into more steps). When you run mypy, you're doing the first step. The types you define in TypeScript you similarly define in Pythin, they just call them annotations, and there's an option to reference them at runtime, but mypy doesn't work at runtime (perhaps that's where the confusion is from?)