From 49a63eeb5068d15e3f0d039c9cdf602c21b2fd8e Mon Sep 17 00:00:00 2001 From: prafull-opensignlabs <93375423+prafull-opensignlabs@users.noreply.github.com> Date: Thu, 28 Aug 2025 16:12:53 +0530 Subject: [PATCH] Update docusaurus.config.js --- docs/docusaurus.config.js | 29 ++++++++++++++++++++++------- 1 file changed, 22 insertions(+), 7 deletions(-) diff --git a/docs/docusaurus.config.js b/docs/docusaurus.config.js index d2cc81475..25fff20a3 100644 --- a/docs/docusaurus.config.js +++ b/docs/docusaurus.config.js @@ -69,14 +69,29 @@ const config = { id: "openapi", docsPluginId: "default", // e.g. "classic" or the plugin-content-docs id config: { - opensign: { // "petstore" is considered the that you will reference in the CLI - specPath: "docs/API-docs/opensign.yaml", // path or URL to the OpenAPI spec - outputDir: "docs/API-docs", // output directory for generated *.mdx and sidebar.js files - sidebarOptions: { - groupPathsBy: "tag", // generate a sidebar.js slice that groups operations by tag + opensign: { + // Optional: put all versions under a single route + routeBasePath: 'api/opensign', + sidebarOptions: { + groupPathsBy: 'tag', + }, + // Define your versions here + versions: { + 'v1': { + specPath: 'docs/API-docs/v1/opensign.yaml', + outputDir: 'docs/API-docs/opensign/v1', + label: 'v1', + // isLatest: false, // default + }, + 'v1.1': { + specPath: 'docs/API-docs/v1.1/opensign.yaml', + outputDir: 'docs/API-docs/opensign/v1.1', + label: 'v1.1', + isLatest: true, // makes this the default version in the UI + }, }, - } - } + }, + }, }, ] ],