### Developer Quick Start Commands Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/AGENTS.md Provides essential commands for setting up the development environment, including cloning the repository, installing dependencies, building packages, and watching for demo site changes. ```bash git clone https://github.com//docusaurus-openapi-docs.git cd docusaurus-openapi-docs yarn yarn build-packages yarn watch:demo ``` -------------------------------- ### Install OpenAPI Theme Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/demo/docs/intro.mdx Install the docusaurus-theme-openapi-docs package using Yarn. ```bash yarn add docusaurus-theme-openapi-docs ``` -------------------------------- ### Install OpenAPI Plugin Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/demo/docs/intro.mdx Install the docusaurus-plugin-openapi-docs package using Yarn. ```bash yarn add docusaurus-plugin-openapi-docs ``` -------------------------------- ### Generate API Docs for 'petstore' Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/demo/docs/intro.mdx Example of generating API documentation specifically for the 'petstore' OpenAPI specification. ```bash yarn docusaurus gen-api-docs petstore ``` -------------------------------- ### Install Beta Version of docusaurus-plugin-openapi-docs Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/AGENTS.md Use this command to install a beta version of the docusaurus-plugin-openapi-docs package. This is useful for testing upcoming features or fixes. ```bash npm install docusaurus-plugin-openapi-docs@beta ``` -------------------------------- ### Changelog Format Example Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/AGENTS.md Provides an example of the categorized changelog format used in the project, including sections for new features, bug fixes, refactoring, documentation, and dependencies. ```markdown ## X.Y.Z (YYYY-MM-DD) Brief summary of the most significant changes in this release (1-3 sentences). - Bullet points highlighting major user-facing features or fixes #### :rocket: New Feature - feat: description of feature ([#123](https://github.com/PaloAltoNetworks/docusaurus-openapi-docs/pull/123)) #### :bug: Bug Fix - fix: description of fix ([#124](https://github.com/PaloAltoNetworks/docusaurus-openapi-docs/pull/124)) #### :house: Refactoring - refactor: description ([#125](https://github.com/PaloAltoNetworks/docusaurus-openapi-docs/pull/125)) #### :memo: Documentation - docs: description ([#126](https://github.com/PaloAltoNetworks/docusaurus-openapi-docs/pull/126)) #### :robot: Dependencies - chore(deps): bump package from X to Y ([#127](https://github.com/PaloAltoNetworks/docusaurus-openapi-docs/pull/127)) ``` -------------------------------- ### Bootstrap Docusaurus Site with OpenAPI Docs Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/demo/docs/intro.mdx Use this command to create a new Docusaurus v3 site pre-configured with docusaurus-openapi-docs and the Petstore API example. ```bash npx create-docusaurus-openapi-docs my-website ``` -------------------------------- ### Clean API Docs for 'petstore' Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/demo/docs/intro.mdx Example of cleaning API documentation specifically for the 'petstore' OpenAPI specification. ```bash yarn docusaurus clean-api-docs petstore ``` -------------------------------- ### Common Task Commands Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/AGENTS.md Includes commands for installing dependencies and building all packages within the project. ```bash yarn yarn build-packages ``` -------------------------------- ### Start Docusaurus Development Server Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/packages/create-docusaurus-openapi-docs/templates/default/docs/intro.md Navigate to your website directory and run this command to build and serve your Docusaurus site locally. The site reloads automatically on changes. ```bash cd my-website npm run start ``` -------------------------------- ### Example Blog Post Markdown File Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/packages/create-docusaurus-openapi-docs/templates/default/docs/tutorial-basics/create-a-blog-post.md Create a file in the `blog/` directory with a date-based name. The front matter includes slug, title, author details, and tags. ```markdown --- slug: greetings title: Greetings! authors: - name: Joel Marcey title: Co-creator of Docusaurus 1 url: https://github.com/JoelMarcey image_url: https://github.com/JoelMarcey.png - name: Sébastien Lorber title: Docusaurus maintainer url: https://sebastienlorber.com image_url: https://github.com/slorber.png tags: [greetings] --- Congratulations, you have made your first post! Feel free to play around and edit this post as much you like. ``` -------------------------------- ### Create a React Page Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/packages/create-docusaurus-openapi-docs/templates/default/docs/tutorial-basics/create-a-page.md Create a React component file in `src/pages` to render a new page. This example shows a basic React page structure. ```jsx import React from "react"; import Layout from "@theme/Layout"; export default function MyReactPage() { return (

My React page

This is a React page

); } ``` -------------------------------- ### Create a Markdown Page Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/packages/create-docusaurus-openapi-docs/templates/default/docs/tutorial-basics/create-a-page.md Create a Markdown file in `src/pages` to render a new page. This example shows a basic Markdown page structure. ```mdx # My Markdown page This is a Markdown page ``` -------------------------------- ### Front Matter Example Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/packages/create-docusaurus-openapi-docs/templates/default/docs/tutorial-basics/markdown-features.mdx Define metadata for a Markdown document using YAML front matter. ```text --- id: my-doc-id title: My document title description: My document description slug: /my-custom-url --- ``` -------------------------------- ### Simple Method Badge Styles Source: https://github.com/paloaltonetworks/docusaurus-openapi-docs/blob/main/demo/docs/customization/styling.mdx Applies simple styling to method badges, similar to those found on pan.dev. This example shows a 'cat' schema and a 'post' method. ```html