docusaurus-openapi-docs icon indicating copy to clipboard operation
docusaurus-openapi-docs copied to clipboard

More detail needed to get plugin working

Open jacknevitt opened this issue 2 years ago • 4 comments

Documentation link

https://github.com/PaloAltoNetworks/docusaurus-openapi-docs#configuring-docusaurusconfigjs-plugin-and-theme-usage

Describe the problem

The guide does not sufficiently describe how to get the plugin working with a docusaurus project. Using the provided code examples does not build any pages.

I have created a new docusaurus project with npx create-docusaurus@latest my-website classic --typescript. I have installed docusaurus-plugin-openapi-docs and docusaurus-theme-openapi-docs (v1.7.3). I have downgraded @docusaurus/core and @docusaurus/preset-classic to v2.2.x as v2.4.0 is not supported by the plugin. I have used the code recommended for the docusaurus.config.js and copied the petstore.yaml file to the project.

Suggested fix

Include more detail in the installation guide to get the plugin working with a typical docusaurus project.

jacknevitt avatar Jul 18 '23 11:07 jacknevitt

:tada: Thanks for opening your first issue here! Welcome to the community!

Hi @jacknevitt , I have also trouble getting the project up and running with latest Docusaurus. From your repository, I cannot see the usage of "docusaurus-theme-openapi-docs" or anything from this repo here. Can you ensure to submit your sample?

PeterMerkert avatar Jul 20 '23 13:07 PeterMerkert

I'm having a similar issue (also downgraded docusaurus to 2.2.0 and installed v1.7.3). When I run docusaurus start, everything seems alright, but when I run docusaurus build I get the following errors:

export 'toString' (imported as 'toString') was not found in 'docusaurus-theme-openapi-docs/lib/markdown/utils' (possible exports: __esModule)
export 'guard' (imported as 'guard') was not found in 'docusaurus-theme-openapi-docs/lib/markdown/utils' (possible exports: __esModule)

I, however, get the same issue when I try using the beta version.

bonimart avatar Jul 20 '23 14:07 bonimart

My apologies @PeterMerkert, I had accidentally overwritten the repo with redocusaurus.

jacknevitt avatar Jul 21 '23 08:07 jacknevitt

Will update docs coinciding with next stable releases.

sserrata avatar Jun 28 '24 19:06 sserrata