Skip to content

Add getOpenAPI3 to OpenAPI3 emitter#2950

Merged
bterlson merged 15 commits intomicrosoft:mainfrom
bterlson:openapi3-function
Feb 26, 2024
Merged

Add getOpenAPI3 to OpenAPI3 emitter#2950
bterlson merged 15 commits intomicrosoft:mainfrom
bterlson:openapi3-function

Conversation

@bterlson
Copy link
Copy Markdown
Member

This function is useful when you want to work with the OpenAPI 3 directly, or don't want to write it to disk for some reason. In my case, I am going to be emitting clients with Kiota, and I want to handle writing the OpenAPI myself, and keep it as an internal implementation detail.

@azure-sdk
Copy link
Copy Markdown
Collaborator

azure-sdk commented Feb 23, 2024

All changed packages have been documented.

@azure-sdk
Copy link
Copy Markdown
Collaborator

You can try these changes at https://cadlplayground.z22.web.core.windows.net/prs/2950/

Check the website changes at https://tspwebsitepr.z22.web.core.windows.net/prs/2950/

bterlson and others added 2 commits February 23, 2024 17:26
Co-authored-by: Timothee Guerin <timothee.guerin@outlook.com>
@bterlson bterlson enabled auto-merge (squash) February 24, 2024 01:37
@bterlson bterlson disabled auto-merge February 24, 2024 01:37
@bterlson bterlson enabled auto-merge (squash) February 24, 2024 01:37
@bterlson bterlson disabled auto-merge February 24, 2024 01:43
version: string;

/** The diagnostics created for this version. */
readonly diagnostics: Readonly<Diagnostic[]>;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
readonly diagnostics: Readonly<Diagnostic[]>;
readonly diagnostics: readonly Diagnostic[];

also should all the props be readonly?

@bterlson bterlson enabled auto-merge (squash) February 26, 2024 22:34
@bterlson bterlson merged commit aa6e53f into microsoft:main Feb 26, 2024
markcowl pushed a commit to markcowl/cadl that referenced this pull request Mar 8, 2024
This function is useful when you want to work with the OpenAPI 3
directly, or don't want to write it to disk for some reason.

---------

Co-authored-by: Timothee Guerin <timothee.guerin@outlook.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants