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

Duplicated Petstore API docs #8

Open
martyna-mindsdb opened this issue Jul 5, 2024 · 3 comments
Open

Duplicated Petstore API docs #8

martyna-mindsdb opened this issue Jul 5, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@martyna-mindsdb
Copy link

martyna-mindsdb commented Jul 5, 2024

Hello,
I have cloned this repository and started the docs by running yarn start without making any modifications to the code.

I noticed that the Petsore API docs are present in the Petstore API tab, which is ok (as marked in green rectangle below), but these are also present in the Tutorial tab under petstore item, which shouldn't be there (as marked in red rectangle below).

image

Please let me know how to remove the petstore item under the Tutorial tab.
Thanks.

EDIT:
I removed this duplicate item by setting the sidebars.ts file content manually, instead of generating it automatically from the docs folder.

@sserrata
Copy link
Member

Hi @martyna-mindsdb, thanks for reporting. This is a result of when autogenerated sidebars overlap with the sidebar generated by the plugin.

@programm-ingovals
Copy link

programm-ingovals commented Nov 7, 2024

What can be done about it though?

The solution seems to be to not autogenerate the sidebar. But autogeneration is what we want. So we wanna skip the api folder for autogeneration.

A few things I tried unsuccessfully.

  1. Pull the petstore folder out of the docs folder and trying to make the petstore API sidebar point to that folder, but docs seems to be required to be in the docs folder.
  2. Put API docs and other docs in separate folders. docs/petstore docs/tutorial and point the autogen dirname to tutorial, should work in theory, but doesn´t.

@sserrata
Copy link
Member

sserrata commented Nov 8, 2024

Hi @programm-ingovals, I recommend consulting docusaurus.io docs for guidance as there are several supported methods/strategies for handling this situation. The generated sidebar.js is intended as a helper but you're correct in that it is not intended to be used alongside autogenerated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants