Skip to content

Conversation

@martindekov
Copy link
Contributor

Problem:

Solution:

Related Issue(s):

Test plan:

Additional documentation or context

Signed-off-by: Martin Dekov <martin.dekov@suse.com>
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR upgrades the Docusaurus documentation framework from v2.4 to v3.9, along with updating related dependencies and GitHub Actions workflows. The changes also include formatting fixes for documentation that were previously incorrectly escaped due to Docusaurus v2 limitations.

  • Major version upgrade from Docusaurus v2.4 to v3.9 with updated plugin ecosystem
  • Migration to new import paths and configuration structure for v3 compatibility
  • Update GitHub Actions workflows to use Node.js 20 and newer action versions

Reviewed changes

Copilot reviewed 13 out of 14 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
package.json Upgrades all Docusaurus packages to v3.9.x, adds @docusaurus/faster, and updates related dependencies (MDX, prism-react-renderer, openapi plugins)
docusaurus.config.js Migrates configuration to v3 structure: updates prism-react-renderer imports, moves onBrokenMarkdownLinks to markdown.hooks, removes webpack config, adds future.experimental_faster flag
src/theme/DocVersionBanner/index.js Updates import paths to use @docusaurus/plugin-content-docs/client instead of deprecated @docusaurus/theme-common/internal
sidebars.js Changes API sidebar import from .js to .ts extension with fallback handling for default export
babel.config.js Removes custom Babel configuration (now handled by Docusaurus v3 internally)
docs/troubleshooting/installation.md Fixes VIP placeholder formatting from escaped to proper inline code format
versioned_docs/version-v1.7/troubleshooting/installation.md Fixes VIP placeholder formatting from escaped to proper inline code format
versioned_docs/version-v1.6/troubleshooting/installation.md Fixes VIP placeholder formatting from escaped to proper inline code format
versioned_docs/version-v1.5/troubleshooting/installation.md Fixes VIP placeholder formatting from escaped to proper inline code format
versioned_docs/version-v1.4/troubleshooting/installation.md Fixes VIP placeholder formatting from escaped to proper inline code format
.github/workflows/release.yml Updates to Node.js 20 and actions/checkout@v6
.github/workflows/pull-request.yml Changes trigger from pull_request_target to pull_request, updates to Node.js 20, and updates to actions/checkout@v6 and actions/setup-node@v6
.github/workflows/algolia-search.yml Updates to actions/checkout@v6

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.


on:
pull_request_target:
pull_request:
Copy link

Copilot AI Jan 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changing from pull_request_target to pull_request can have security implications. The pull_request_target event runs in the context of the target repository and has access to repository secrets, which is safer for pull requests from forks. The pull_request event runs in the context of the fork and should not have access to secrets.

If this workflow uses any repository secrets or needs to comment on PRs from forks, this change could break functionality or create security issues. Ensure this change is intentional and that the workflow doesn't require elevated permissions.

Suggested change
pull_request:
pull_request_target:

Copilot uses AI. Check for mistakes.
Comment on lines +15 to +19
markdown: {
hooks: {
onBrokenMarkdownLinks: "warn",
},
},
Copy link

Copilot AI Jan 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The configuration property onBrokenMarkdownLinks has been moved incorrectly. In Docusaurus v3, onBrokenMarkdownLinks should remain as a top-level configuration option, not nested under markdown.hooks. According to the Docusaurus v3 documentation, the correct structure should be:

onBrokenMarkdownLinks: "warn",
markdown: {
  // other markdown options
},

This change may cause the broken markdown links warning to not work as expected.

Suggested change
markdown: {
hooks: {
onBrokenMarkdownLinks: "warn",
},
},
onBrokenMarkdownLinks: "warn",
markdown: {},

Copilot uses AI. Check for mistakes.

// @ts-check

const apiSidebar = require("./docs/api/sidebar.ts");
Copy link

Copilot AI Jan 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code is requiring a .ts file but using the .require() syntax which expects CommonJS modules. TypeScript files are typically ES modules that export via export default. The fallback apiSidebar.default || apiSidebar on line 29 suggests uncertainty about the module format.

Since the file is sidebar.ts (TypeScript), and this is a JavaScript file using require(), this may cause issues at runtime if the sidebar.ts file doesn't exist or uses ES module syntax. Consider either:

  1. Using sidebar.js instead of sidebar.ts in the require statement if the generated file is JavaScript
  2. Or ensure the file extension matches what is actually generated by docusaurus-plugin-openapi-docs
Suggested change
const apiSidebar = require("./docs/api/sidebar.ts");
const apiSidebar = require("./docs/api/sidebar.js");

Copilot uses AI. Check for mistakes.
"@docusaurus/preset-classic": "^2.4.0",
"@mdx-js/react": "^1.6.22",
"@docusaurus/core": "^3.9.0",
"@docusaurus/faster": "^3.9.2",
Copy link

Copilot AI Jan 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's a version mismatch in the Docusaurus packages. Most packages are at ^3.9.0, but @docusaurus/faster is at ^3.9.2. While this might work, it's better practice to keep all Docusaurus packages aligned to the same version to avoid potential compatibility issues. Consider updating this to ^3.9.0 to match the other packages.

Suggested change
"@docusaurus/faster": "^3.9.2",
"@docusaurus/faster": "^3.9.0",

Copilot uses AI. Check for mistakes.
@github-actions
Copy link

github-actions bot commented Jan 6, 2026

Name Link
🔨 Latest commit cc36e3e
😎 Deploy Preview https://695d36cc2dd041bc91b0f6b1--harvester-preview.netlify.app

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants