Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import single model defenition inside mdx files. #46

Closed
hleb-albau opened this issue May 20, 2021 · 3 comments · Fixed by #87
Closed

Import single model defenition inside mdx files. #46

hleb-albau opened this issue May 20, 2021 · 3 comments · Fixed by #87
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@hleb-albau
Copy link

Is it possible to import a single model definition inside .mdx file? I want to have raw /api/ ReDoc endpoint, but also use openapi models inside main documentation. Thanks

@rohit-gohri rohit-gohri added the enhancement New feature or request label May 20, 2021
@rohit-gohri
Copy link
Owner

That would be pretty cool, redoc does expose SchemaDefinition component directly. Will see if it is possible.

@rohit-gohri
Copy link
Owner

Something like this?

import ApiSchema from '@theme/ApiSchema';

<ApiSchema
  schemaRef="#/components/schemas/Pet"
/>

image

@rohit-gohri
Copy link
Owner

With only schema and example hidden

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants