You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This proposal aims to introduce a transpilation-free syntax that allows developers to add certain TypeScript features without transpiling TypeScript to JavaScript. This syntax will be implemented through special comment markers, enabling TypeScript's type safety while reducing transpilation steps. This proposal is not intended to eliminate the transpilation step of TypeScript, but rather to provide an alternative option for JSDoc users.
In this syntax, content between /*: and */ is considered TypeScript features.
The syntax is primarily designed for type annotations, so certain specific TypeScript syntax (such as enum, interface) may not be available. If developers want to use these potentially unavailable syntaxes, JavaScript developers may need to write code twice in one file, once for TypeScript and once for JavaScript.
π Motivating Example
By introducing transpilation-free syntax, JavaScript developers can use TypeScript's powerful type system and development tool support without transpilation.
π» Use Cases
What do you want to use this for?
Use TypeScript's powerful type system and development tool support without transpilation.
What shortcomings exist with current approaches?
TypeScript needed to be transpiled before running.
What workarounds are you using in the meantime?
Use JSDoc. JSDoc is more verbose than TypeScript.
The text was updated successfully, but these errors were encountered:
π Search Terms
transpilation-free, /*:
β Viability Checklist
β Suggestion
This proposal aims to introduce a transpilation-free syntax that allows developers to add certain TypeScript features without transpiling TypeScript to JavaScript. This syntax will be implemented through special comment markers, enabling TypeScript's type safety while reducing transpilation steps. This proposal is not intended to eliminate the transpilation step of TypeScript, but rather to provide an alternative option for JSDoc users.
Transpilation-Free Syntax:
/*:
/*:
and*/
is considered TypeScript features.The syntax is primarily designed for type annotations, so certain specific TypeScript syntax (such as enum, interface) may not be available. If developers want to use these potentially unavailable syntaxes, JavaScript developers may need to write code twice in one file, once for TypeScript and once for JavaScript.
π Motivating Example
By introducing transpilation-free syntax, JavaScript developers can use TypeScript's powerful type system and development tool support without transpilation.
π» Use Cases
Use TypeScript's powerful type system and development tool support without transpilation.
TypeScript needed to be transpiled before running.
Use JSDoc. JSDoc is more verbose than TypeScript.
The text was updated successfully, but these errors were encountered: