Socket
Socket
Sign inDemoInstall

docusaurus-plugin-openapi

Package Overview
Dependencies
15
Maintainers
1
Versions
37
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    docusaurus-plugin-openapi

OpenAPI plugin for Docusaurus.


Version published
Weekly downloads
3.9K
increased by23.85%
Maintainers
1
Created
Weekly downloads
 

Changelog

Source

0.7.0 (Dec 13, 2023)

High-level enhancements

  • Docusaurus v3 support (#266)
  • Allow pressing enter to perform the 'Execute' action (#255)
  • Render examples in a <code> block (#256)

Other enhancements and bug fixes

  • Wrap code examples tabs in narrow browser windows (#250)
  • Add border to form inputs when using light theme (#252)
  • Fix: Page crash on half surrogate pair (#261)

Readme

Source

Docusaurus OpenAPI

OpenAPI plugin for generating API reference docs in Docusaurus v2.

Multiple OpenAPI Definitions

To have more than one OpenAPI pages, add additional OpenAPI plugin instances:

/* docusaurus.config.js */

{
  presets: [
    [
      'docusaurus-preset-openapi',
      {
        api: {
          // id: 'cars', // omitted => default instance
          path: 'cars/openapi.json',
          routeBasePath: 'cars',
          // ... other options
        },
      },
    ],
  ],
  plugins: [
    [
      'docusaurus-plugin-openapi',
      {
        id: 'trains',
        path: 'trains/openapi.json',
        routeBasePath: 'trains',
        // ... other options
      },
    ],
    [
      'docusaurus-plugin-openapi',
      {
        id: 'bikes',
        path: 'bikes/openapi.json',
        routeBasePath: 'bikes',
        // ... other options
      },
    ],
  ],
}

This will create routes for /cars, /trains and /bikes.

Note: One instance of the plugin is included in the preset. All additional plugin instances will require an id.

FAQs

Last updated on 14 Dec 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc