Overview
TypeSpec library for emitting TypeSpec to JSON Schema and converting JSON Schema to TypeSpec
Install
- In a spec
- In a library
npm install @typespec/json-schema
npm install --save-peer @typespec/json-schema
Emitter usage
TypeSpec.JsonSchema
Decorators
@baseUri
@contains
@contentEncoding
@contentMediaType
@contentSchema
@extension
@id
@jsonSchema
@maxContains
@maxProperties
@minContains
@minProperties
@multipleOf
@oneOf
@prefixItems
@uniqueItems