TypeScript

13 features: 4 implemented, 3 partial, 1 planned, 5 excluded. Back to all areas.

FeatureStatusWhat worksTest
Assertions and satisfiesimplementedThe as, as const, satisfies, postfix non-null and prefix angle-bracket forms preserve the operand and its effects. Expression lowering honors the relational precedence of as and satisfies, including when a later arithmetic operator changes grouping. An assertion alone does not select a representation or an own-property layout.tests/assertions.ts
Command-line argument annotationimplementedThe single string[] parameter on exported main uses the CLI input boundary. This syntax supports that parameter convention alone.
EnumsexcludedEmitting enum objects and reverse mappings requires TypeScript-specific runtime code.
Generics and overloadspartialErases parsed instantiation and type argument lists on ordinary calls, method calls and constructor expressions. Evaluation keeps the original callee, receiver and arguments. Generic functions, function expressions, methods and arrows erase their type parameters. Record constraints can suggest guarded field ordinals, with lexical shadowing and defaults resolved independently. Erasure preserves the original callable and arguments. Bodyless overload signatures disappear; all calls reach the single runtime implementation. Ambient function declarations create no global binding. Full static overload resolution is outside the runtime compiler. General type-level substitution remains open. See tests/type-arguments.ts, tests/generic-shapes.ts and tests/assertions.ts.
Parameter properties and decoratorsexcludedImplicit class initialization and decoration are outside the erasable scalar profile.
Relative TypeScript importsimplementedExplicit named value imports with a literal .ts specifier relative to the importing source. Source discovery uses the same module graph as JavaScript.
Runtime namespacesexcludedNamespacing uses standard modules. Namespace emit requires TypeScript-specific runtime code.
Scalar annotationsimplementedOptional number, bigint and boolean annotations on named function parameters, return types, and initialized local bindings. A void return annotation marks a procedure. The compiler checks the supported representations. A dynamically typed return expression widens a scalar return annotation to preserve the concrete JavaScript result.
tsconfig and project type checkingexcludedThe standalone compiler consumes an explicit source graph and checks the facts it needs to emit executable code. Project-wide diagnostics belong to a separate TypeScript tool.
TSXexcludedUI-specific source syntax belongs in a separate build step.
Type aliases and interfacespartialErases type-only declarations. Inline object annotations, named interfaces and source-local alias chains on parameters and local lexical declarations suggest ordinals for named reads and writes. A local initialized with a record literal can supply the same prediction in JavaScript. Captures carry the layout hint. An ordinal is verified against the live own data property on every access. Reordering, inherited fields, read-only properties and primitive receivers retain normal behavior. Type parameters are scoped to their declarations. A named or inline record bound, including another constrained parameter, supplies a prediction. A generic record alias or interface contributes its fixed member names. Record with a finite union of string-literal keys can predict slots, while an open index or a default type alone supplies none. Source-local interface bases and unparenthesized record intersections are visited in declaration order. Repeated fields, including diamond inheritance, share one ordinal. A derived field can refine the nested declaration. Optional fields and the name-preserving utilities Partial, Required and Readonly supply hints under the same runtime checks. Absent properties, reordered records, inherited accessors and frozen objects preserve JavaScript semantics. Cyclic declarations, unions and ambiguous source-local names use ordinary lookup. Imported and merged layouts and full type-level computation remain open. See tests/shape-hints.ts, tests/shape-writes.ts, tests/generic-shapes.ts, tests/composed-shapes.ts and tests/nested-shapes.ts.
Type-only imports and declarationsplannedType-only dependency tracking is separate from loading a runtime source. Declaration files provide no runtime representation guarantees.
Union, intersection, and object typespartialSimple unions and structural object annotations use tagged runtime values. Named and inline object parameters can carry guarded field-slot suggestions. A union does not imply a particular object layout. General intersection annotations remain open.
At tinyscript commit 0c5984ec; each test is a program that runs the feature.