January 2024
New Features
@typespec/compiler New Features
- New Language Feature Added support for named template arguments. Typespec template arguments can now be instantiated both positionally and by name. See this issue for details.
- All TypeSpec libraries normalized Template parameter names in anticipation of this change.
 
- Renamed template parameters in preparation for named template argument instantiation.
- Added new --templateoption totsp initcommand line action which lets user specify which template to choose from in the template list.
- Added a new init template for creating a new TypeSpec emitter.
- Added a new init template for creating a new TypeSpec library.
- New Language Feature Added the ability to use another template parameter as a constraint, e.g. model Foo<A, B extends A>.
- Added @encodedNamedecorator andgetEncodedNameaccessor.
- Added support for bytes encode to the general encode type.
- Library declaration: Enabled declaration of State symbols in the library declaration, providing a central place to define state symbols used in your libraries.
- Added a new helper function to change casing to the init templates.
@typespec/bundler New Features
- Support for the typesentry underexportsin package definitions (instead of the legacytypesVersions).- All TypeSpec libraries are now using this definition style.
 
- Add a new cli for typespec-bundler.
- Expose a bundle manifest with relative importmap, package name, and version.
@typespec/openapi3 New Features
- Added support for @encodedNamedecorator.
@typespec/playground New features
- Added a format button to the playground command bar.
- Added a notification to the standalone playground when the playground has been saved.
- Added resizable panes for the editor and output.
- Added the ability to pass a custom footer and use FooterandFooterItemcomponent to build your own.
- Added the ability to configure the playground via createBrowserHostif library loading should use systemimportmapor the es-module-shim library withimportmap-shim. This was added due to the lack of support for external source map in browsers.
- Provided the ability to configure bundling local libraries with the playground or manage the importmapyourself withskipBundleLibrariesoption.
- Moved errors and warnings to a dedicated expandable banner at the bottom of the playground.
- Removed githubIssueUrllink and replaced with aonFileBugcallback.
- Allowed standalone playground to show a loading fallback.
Bug Fixes
@typespec/compiler Bug Fixes
- Fix: Improved performance of the language server, impacting performance of syntax highlighting and other IDE features.
- Fix: Enabled compiler file resolution for long path names (256+ characters) on windows.
- Fix: Turned off warning when tsp initis used with a template that does not specifycompilerVersion.
@typespec/http Bug Fixes
- Fix: Ensured @pathcustom name is respected.
- Fix: Allowed correct path generation when path parameter is not alpha numeric(Either with a different name provided in @pathor if the property name is not an identifier)
@typespec/playground Bug Fixes
- Fix: Configured the program viewer to respect the color theme.
- Fix: Provided css exports to styles.cssin addition tostyle.css. Both are now available for backward compatibility butstyles.cssis the recommended name.
@typespec/rest Bug Fixes
- Fix: Corrected handling of custom @path name in the building of the route.
@typespec/versioning Bug Fixes
Deprecations
@typespec-compiler Deprecations
- Library declaration: Deprecated linter property on $libin favor of a new$lintervariable that can be exported. This was done to discourage circular references caused by referencing linter rules in$lib.
Breaking Changes
Node Version Requirement
- TypeSpec dropped support for node version 16, as this version of node is no longer generally supported. Minimum node version is 18.
typespec-playground Breaking Changes
- BREAKING CHANGE Styles must be imported seperately with import \"@typespec/playground/styles.css\";.