MyGit

typespec@0.59.0

microsoft/typespec

版本发布时间: 2024-08-08 13:41:08

microsoft/typespec最新发布版本:@typespec/rest@0.59.1(2024-08-13 22:50:27)

@typespec/compiler

Bug Fixes

Bump dependencies

Features

Breaking Changes

@typespec/http

Bug Fixes

Bump dependencies

Features

Deprecations

@typespec/versioning

Bug Fixes

Bump dependencies

@typespec/rest

Bump dependencies

Features

@typespec/openapi

Bump dependencies

@typespec/openapi3

Bug Fixes

Bump dependencies

Features

@typespec/protobuf

Bug Fixes

Bump dependencies

@typespec/prettier-plugin-typespec

Bump dependencies

@typespec/eslint-plugin

Bump dependencies

@typespec/html-program-viewer

Bump dependencies

@typespec/json-schema

Bump dependencies

Breaking Changes

In previous versions of the json-schema emitter, the @extension decorator only accepted types as the value. These are emitted as JSON schemas. In order to add extensions as raw values, types had to be wrapped in the Json<> template when being passed to the @extension decorator.

This change allows setting TypeSpec values (introduced in TypeSpec 0.57.0) directly instead.

The following example demonstrates using values directly:

@extension("x-example", #{ foo: "bar" })
model Foo {}

This change results in scalars being treated as values instead of types. This will result in the @extension decorator emitting raw values for scalar types instead of JSON schema. To preserve the previous behavior, use typeof when passing in a scalar value.

The following example demonstrates how to pass a scalar value that emits a JSON schema:

@extension("x-example", "foo")
model Foo {}

To preserve this same behavior, the above example can be updated to the following:

@extension("x-example", typeof "foo")
model Foo {}

@typespec/internal-build-utils

Bump dependencies

typespec-vs

Bug Fixes

typespec-vscode

Bump dependencies

@typespec/library-linter

Bump dependencies

相关地址:原始地址 下载(tar) 下载(zip)

查看:2024-08-08发行的版本