The Types as Comments proposal means that browsers could run TypeScript-checked code directly, (even though they wouldn't do any type-checking). That means faster iteration with all the type-checking and editing experience you know and love today.


We're excited to hear what you think of this idea! We're hoping that this proposal can make coding easier for TypeScript and JavaScript users at every scale.


Typescript can already run ES modules directly, with inline type checking in VSCode or CLI type checking using TSC When the types are defined using JSDoc This change to the ECMA262 spec is a regression from existing functionality


How does this differ from JSDOCS?


This comment clarified it more, because type-checking in browser wouldn't make it better, in fact it would move the error from compile to runtime and also slow down. But just being able to run and ignore the types - yes, that has benefits for development


United States Trends
Loading...

Something went wrong.


Something went wrong.