Skip to content

Conversation

@jonniebigodes
Copy link
Contributor

@jonniebigodes jonniebigodes commented Dec 14, 2025

Closes #

What I did

Fixed the documentation links in the codebase to prevent them from returning 404 errors, and renamed sections in the documentation.

What was done:

  • Scanned and fixed links to the latest iteration of the documentation across the various addons, packages, and frameworks we currently support.

Checklist for Contributors

Testing

The changes in this PR are covered in the following automated tests:

  • stories
  • unit tests
  • integration tests
  • end-to-end tests

Manual testing

This section is mandatory for all contributions. If you believe no manual test is necessary, please state so explicitly. Thanks!

Documentation

  • Add or update documentation reflecting your changes
  • If you are deprecating/removing a feature, make sure to update
    MIGRATION.MD

Checklist for Maintainers

  • When this PR is ready for testing, make sure to add ci:normal, ci:merged or ci:daily GH label to it to run a specific set of sandboxes. The particular set of sandboxes can be found in code/lib/cli-storybook/src/sandbox-templates.ts

  • Make sure this PR contains one of the labels below:

    Available labels
    • bug: Internal changes that fixes incorrect behavior.
    • maintenance: User-facing maintenance tasks.
    • dependencies: Upgrading (sometimes downgrading) dependencies.
    • build: Internal-facing build tooling & test updates. Will not show up in release changelog.
    • cleanup: Minor cleanup style change. Will not show up in release changelog.
    • documentation: Documentation only changes. Will not show up in release changelog.
    • feature request: Introducing a new feature.
    • BREAKING CHANGE: Changes that break compatibility in some way with current major version.
    • other: Changes that don't fit in the above categories.

🦋 Canary release

This PR does not have a canary release associated. You can request a canary release of this pull request by mentioning the @storybookjs/core team here.

core team members can create a canary release here or locally with gh workflow run --repo storybookjs/storybook publish.yml --field pr=<PR_NUMBER>

Summary by CodeRabbit

  • Documentation
    • Updated documentation links and references throughout the codebase to reflect current Storybook documentation structure and paths.
    • Improved JSDoc comments and inline documentation for better clarity on feature configuration and disabling options.
    • Updated Next.js-related guidance to reference Next.js + Vite integration resources where applicable.
    • Corrected documentation anchors and URL paths to ensure proper navigation to relevant guides.

✏️ Tip: You can customize this high-level summary in your review settings.

@valentinpalkovic valentinpalkovic changed the title Fix: Adjust incorrect and outdated links in the codebase Documentation: Adjust incorrect and outdated links in the codebase Dec 15, 2025
@valentinpalkovic valentinpalkovic added ci:daily Run the CI jobs that normally run in the daily job. documentation ci:docs Run the CI jobs for documentation checks only. and removed ci:daily Run the CI jobs that normally run in the daily job. labels Dec 15, 2025
@nx-cloud
Copy link

nx-cloud bot commented Dec 15, 2025

View your CI Pipeline Execution ↗ for commit fb4ea6b

Command Status Duration Result
nx run-many -t compile,check,knip,test,pretty-d... ❌ Failed 15m 59s View ↗

☁️ Nx Cloud last updated this comment at 2025-12-15 14:22:00 UTC

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 15, 2025

📝 Walkthrough

Walkthrough

This PR updates external documentation references and JSDoc comments across the codebase. Documentation links are redirected to current documentation paths, more specific sections, or advanced variants. User-facing error and warning messages are updated with revised documentation URLs. No functional or behavioral logic changes.

Changes

Cohort / File(s) Change Summary
Type definitions — documentation link and JSDoc updates
code/addons/a11y/src/types.ts, code/addons/docs/src/types.ts, code/builders/builder-webpack5/src/types.ts, code/core/src/actions/types.ts, code/core/src/backgrounds/types.ts, code/core/src/controls/types.ts, code/core/src/highlight/types.ts, code/core/src/measure/types.ts, code/core/src/outline/types.ts, code/core/src/viewport/types.ts, code/frameworks/angular/src/client/public-types.ts, code/frameworks/nextjs-vite/src/types.ts, code/frameworks/react-vite/src/types.ts
JSDoc comments updated with revised documentation URLs and link anchors; some comments expanded with additional guidance text. Documentation links redirected to current paths (e.g., version-specific to version-agnostic URLs, or to more specific subsections).
Core server and utilities — error/warning message links
code/core/src/cli/eslintPlugin.ts, code/core/src/core-server/presets/common-preset.ts, code/core/src/core-server/utils/StoryIndexGenerator.ts, code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts, code/core/src/preview-api/modules/preview-web/parseArgsParam.ts, code/core/src/preview-errors.ts, code/core/src/server-errors.ts, code/renderers/react/src/entry-preview.tsx
User-facing error and warning messages updated with revised documentation URLs, URL anchors corrected or standardized.
Mobile and component UI — link updates
code/core/src/manager/components/mobile/about/MobileAbout.tsx
href URL updated in LinkLine component.
Vitest addon — setup and preset links
code/addons/vitest/src/postinstall.ts, code/addons/vitest/src/preset.ts
Documentation URLs updated from standard to advanced setup sections; log message text updated to reference "Storybook's Vitest addon" and point to Next.js + Vite integration guide.
CLI and automation tools — link updates
code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts, code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts, code/lib/cli-storybook/src/codemod/csf-factories.ts, code/lib/cli-storybook/src/warn.ts, code/lib/create-storybook/src/commands/AddonConfigurationCommand.ts
Documentation URLs in automigration logic and command utilities updated to current paths; vitest addon setup link changed to advanced variant.
Framework documentation and templates
code/frameworks/angular/template/stories/others/ngx-translate/README.mdx, code/frameworks/html-vite/template/cli/ts/Header.stories.ts, code/frameworks/nextjs-vite/README.md
README and template comment links updated; decorators documentation link changed to generic renderer-agnostic path with Angular parameter; comment line removed from story template.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

  • Review scope: Large number of files (27+) but with repetitive, homogeneous changes across the codebase—primarily documentation URL updates and JSDoc comment expansions.
  • Attention areas:
    • Verify URL redirects are correct and point to intended documentation sections (check a sample of the updated links to ensure they exist and are current).
    • Confirm anchor fragments in URLs (e.g., #experimentaltestsyntax vs. #experimentalTestSyntax) match target documentation.
    • Ensure version-specific URLs (e.g., /docs/10/) transitioning to version-agnostic paths (e.g., /docs/) do not break existing links or cause redirect chains.

Possibly related PRs

  • storybookjs/storybook#33316: Modifies the same automigration fixer (nextjs-to-nextjs-vite.ts) to conditionally add Vite; this PR updates only the informational link in that same file.
  • storybookjs/storybook#32624: Normalizes CLI and automigration user-facing documentation URLs during upgrade workflows; related scope and pattern of link corrections.
✨ Finishing touches
  • 📝 Generate docstrings

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 4cd6783 and fb4ea6b.

📒 Files selected for processing (32)
  • code/addons/a11y/src/types.ts (1 hunks)
  • code/addons/docs/src/types.ts (0 hunks)
  • code/addons/vitest/src/postinstall.ts (5 hunks)
  • code/addons/vitest/src/preset.ts (1 hunks)
  • code/builders/builder-webpack5/src/types.ts (1 hunks)
  • code/core/src/actions/types.ts (1 hunks)
  • code/core/src/backgrounds/types.ts (1 hunks)
  • code/core/src/cli/eslintPlugin.ts (1 hunks)
  • code/core/src/controls/types.ts (1 hunks)
  • code/core/src/core-server/presets/common-preset.ts (1 hunks)
  • code/core/src/core-server/utils/StoryIndexGenerator.ts (1 hunks)
  • code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts (1 hunks)
  • code/core/src/highlight/types.ts (1 hunks)
  • code/core/src/manager/components/mobile/about/MobileAbout.tsx (1 hunks)
  • code/core/src/measure/types.ts (1 hunks)
  • code/core/src/outline/types.ts (1 hunks)
  • code/core/src/preview-api/modules/preview-web/parseArgsParam.ts (1 hunks)
  • code/core/src/preview-errors.ts (1 hunks)
  • code/core/src/server-errors.ts (7 hunks)
  • code/core/src/viewport/types.ts (1 hunks)
  • code/frameworks/angular/src/client/public-types.ts (3 hunks)
  • code/frameworks/angular/template/stories/others/ngx-translate/README.mdx (1 hunks)
  • code/frameworks/html-vite/template/cli/ts/Header.stories.ts (0 hunks)
  • code/frameworks/nextjs-vite/README.md (1 hunks)
  • code/frameworks/nextjs-vite/src/types.ts (1 hunks)
  • code/frameworks/react-vite/src/types.ts (1 hunks)
  • code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts (1 hunks)
  • code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts (1 hunks)
  • code/lib/cli-storybook/src/codemod/csf-factories.ts (2 hunks)
  • code/lib/cli-storybook/src/warn.ts (1 hunks)
  • code/lib/create-storybook/src/commands/AddonConfigurationCommand.ts (1 hunks)
  • code/renderers/react/src/entry-preview.tsx (1 hunks)
💤 Files with no reviewable changes (2)
  • code/frameworks/html-vite/template/cli/ts/Header.stories.ts
  • code/addons/docs/src/types.ts
🧰 Additional context used
📓 Path-based instructions (6)
**/*.{js,jsx,json,html,ts,tsx,mjs}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

Use ESLint and Prettier configurations that are enforced in the codebase

Files:

  • code/core/src/manager/components/mobile/about/MobileAbout.tsx
  • code/addons/a11y/src/types.ts
  • code/core/src/backgrounds/types.ts
  • code/core/src/server-errors.ts
  • code/core/src/viewport/types.ts
  • code/lib/cli-storybook/src/codemod/csf-factories.ts
  • code/core/src/cli/eslintPlugin.ts
  • code/renderers/react/src/entry-preview.tsx
  • code/addons/vitest/src/preset.ts
  • code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts
  • code/core/src/actions/types.ts
  • code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts
  • code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts
  • code/frameworks/nextjs-vite/src/types.ts
  • code/frameworks/react-vite/src/types.ts
  • code/builders/builder-webpack5/src/types.ts
  • code/core/src/preview-errors.ts
  • code/core/src/core-server/utils/StoryIndexGenerator.ts
  • code/lib/create-storybook/src/commands/AddonConfigurationCommand.ts
  • code/core/src/preview-api/modules/preview-web/parseArgsParam.ts
  • code/addons/vitest/src/postinstall.ts
  • code/frameworks/angular/src/client/public-types.ts
  • code/core/src/outline/types.ts
  • code/core/src/core-server/presets/common-preset.ts
  • code/core/src/controls/types.ts
  • code/core/src/measure/types.ts
  • code/core/src/highlight/types.ts
  • code/lib/cli-storybook/src/warn.ts
**/*.{ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

Enable TypeScript strict mode

Files:

  • code/core/src/manager/components/mobile/about/MobileAbout.tsx
  • code/addons/a11y/src/types.ts
  • code/core/src/backgrounds/types.ts
  • code/core/src/server-errors.ts
  • code/core/src/viewport/types.ts
  • code/lib/cli-storybook/src/codemod/csf-factories.ts
  • code/core/src/cli/eslintPlugin.ts
  • code/renderers/react/src/entry-preview.tsx
  • code/addons/vitest/src/preset.ts
  • code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts
  • code/core/src/actions/types.ts
  • code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts
  • code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts
  • code/frameworks/nextjs-vite/src/types.ts
  • code/frameworks/react-vite/src/types.ts
  • code/builders/builder-webpack5/src/types.ts
  • code/core/src/preview-errors.ts
  • code/core/src/core-server/utils/StoryIndexGenerator.ts
  • code/lib/create-storybook/src/commands/AddonConfigurationCommand.ts
  • code/core/src/preview-api/modules/preview-web/parseArgsParam.ts
  • code/addons/vitest/src/postinstall.ts
  • code/frameworks/angular/src/client/public-types.ts
  • code/core/src/outline/types.ts
  • code/core/src/core-server/presets/common-preset.ts
  • code/core/src/controls/types.ts
  • code/core/src/measure/types.ts
  • code/core/src/highlight/types.ts
  • code/lib/cli-storybook/src/warn.ts
code/**/*.{ts,tsx,js,jsx,mjs}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

code/**/*.{ts,tsx,js,jsx,mjs}: Use server-side logger from 'storybook/internal/node-logger' for Node.js code
Use client-side logger from 'storybook/internal/client-logger' for browser code
Do not use console.log, console.warn, or console.error directly unless in isolated files where importing loggers would significantly increase bundle size

Files:

  • code/core/src/manager/components/mobile/about/MobileAbout.tsx
  • code/addons/a11y/src/types.ts
  • code/core/src/backgrounds/types.ts
  • code/core/src/server-errors.ts
  • code/core/src/viewport/types.ts
  • code/lib/cli-storybook/src/codemod/csf-factories.ts
  • code/core/src/cli/eslintPlugin.ts
  • code/renderers/react/src/entry-preview.tsx
  • code/addons/vitest/src/preset.ts
  • code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts
  • code/core/src/actions/types.ts
  • code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts
  • code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts
  • code/frameworks/nextjs-vite/src/types.ts
  • code/frameworks/react-vite/src/types.ts
  • code/builders/builder-webpack5/src/types.ts
  • code/core/src/preview-errors.ts
  • code/core/src/core-server/utils/StoryIndexGenerator.ts
  • code/lib/create-storybook/src/commands/AddonConfigurationCommand.ts
  • code/core/src/preview-api/modules/preview-web/parseArgsParam.ts
  • code/addons/vitest/src/postinstall.ts
  • code/frameworks/angular/src/client/public-types.ts
  • code/core/src/outline/types.ts
  • code/core/src/core-server/presets/common-preset.ts
  • code/core/src/controls/types.ts
  • code/core/src/measure/types.ts
  • code/core/src/highlight/types.ts
  • code/lib/cli-storybook/src/warn.ts
code/**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

Export functions that need to be tested from their modules

Files:

  • code/core/src/manager/components/mobile/about/MobileAbout.tsx
  • code/addons/a11y/src/types.ts
  • code/core/src/backgrounds/types.ts
  • code/core/src/server-errors.ts
  • code/core/src/viewport/types.ts
  • code/lib/cli-storybook/src/codemod/csf-factories.ts
  • code/core/src/cli/eslintPlugin.ts
  • code/renderers/react/src/entry-preview.tsx
  • code/addons/vitest/src/preset.ts
  • code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts
  • code/core/src/actions/types.ts
  • code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts
  • code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts
  • code/frameworks/nextjs-vite/src/types.ts
  • code/frameworks/react-vite/src/types.ts
  • code/builders/builder-webpack5/src/types.ts
  • code/core/src/preview-errors.ts
  • code/core/src/core-server/utils/StoryIndexGenerator.ts
  • code/lib/create-storybook/src/commands/AddonConfigurationCommand.ts
  • code/core/src/preview-api/modules/preview-web/parseArgsParam.ts
  • code/addons/vitest/src/postinstall.ts
  • code/frameworks/angular/src/client/public-types.ts
  • code/core/src/outline/types.ts
  • code/core/src/core-server/presets/common-preset.ts
  • code/core/src/controls/types.ts
  • code/core/src/measure/types.ts
  • code/core/src/highlight/types.ts
  • code/lib/cli-storybook/src/warn.ts
code/**/*.{js,jsx,json,html,ts,tsx,mjs}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

code/**/*.{js,jsx,json,html,ts,tsx,mjs}: Run Prettier with --write flag to format code before committing
Run ESLint with yarn lint:js:cmd to check for linting issues and fix errors before committing

Files:

  • code/core/src/manager/components/mobile/about/MobileAbout.tsx
  • code/addons/a11y/src/types.ts
  • code/core/src/backgrounds/types.ts
  • code/core/src/server-errors.ts
  • code/core/src/viewport/types.ts
  • code/lib/cli-storybook/src/codemod/csf-factories.ts
  • code/core/src/cli/eslintPlugin.ts
  • code/renderers/react/src/entry-preview.tsx
  • code/addons/vitest/src/preset.ts
  • code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts
  • code/core/src/actions/types.ts
  • code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts
  • code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts
  • code/frameworks/nextjs-vite/src/types.ts
  • code/frameworks/react-vite/src/types.ts
  • code/builders/builder-webpack5/src/types.ts
  • code/core/src/preview-errors.ts
  • code/core/src/core-server/utils/StoryIndexGenerator.ts
  • code/lib/create-storybook/src/commands/AddonConfigurationCommand.ts
  • code/core/src/preview-api/modules/preview-web/parseArgsParam.ts
  • code/addons/vitest/src/postinstall.ts
  • code/frameworks/angular/src/client/public-types.ts
  • code/core/src/outline/types.ts
  • code/core/src/core-server/presets/common-preset.ts
  • code/core/src/controls/types.ts
  • code/core/src/measure/types.ts
  • code/core/src/highlight/types.ts
  • code/lib/cli-storybook/src/warn.ts
code/{addons,frameworks}/**/README.md

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

Include code examples in addon/framework documentation for significant changes

Files:

  • code/frameworks/nextjs-vite/README.md
🧠 Learnings (27)
📓 Common learnings
Learnt from: Sidnioulz
Repo: storybookjs/storybook PR: 32458
File: code/core/src/components/components/Select/Select.tsx:200-204
Timestamp: 2025-11-05T09:38:47.712Z
Learning: Repo: storybookjs/storybook — Guidance: Until Storybook 11 is released, do not suggest using React.useId anywhere (e.g., in code/core/src/components/components/Select/Select.tsx) to maintain compatibility with React 17 runtimes. Prefer advising: accept a caller-provided props.id and, if needed, generate a client-only fallback id to minimize SSR hydration issues — but avoid useId. Resume prompting for useId after Storybook 11.
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to README.md : Update relevant README files for significant code changes
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to docs/**/migration*.md : Update migration guides for breaking changes
📚 Learning: 2025-11-05T09:38:47.712Z
Learnt from: Sidnioulz
Repo: storybookjs/storybook PR: 32458
File: code/core/src/components/components/Select/Select.tsx:200-204
Timestamp: 2025-11-05T09:38:47.712Z
Learning: Repo: storybookjs/storybook — Guidance: Until Storybook 11 is released, do not suggest using React.useId anywhere (e.g., in code/core/src/components/components/Select/Select.tsx) to maintain compatibility with React 17 runtimes. Prefer advising: accept a caller-provided props.id and, if needed, generate a client-only fallback id to minimize SSR hydration issues — but avoid useId. Resume prompting for useId after Storybook 11.

Applied to files:

  • code/core/src/manager/components/mobile/about/MobileAbout.tsx
  • code/lib/cli-storybook/src/codemod/csf-factories.ts
  • code/renderers/react/src/entry-preview.tsx
  • code/frameworks/nextjs-vite/README.md
  • code/addons/vitest/src/preset.ts
  • code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts
  • code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts
  • code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts
  • code/builders/builder-webpack5/src/types.ts
  • code/core/src/core-server/utils/StoryIndexGenerator.ts
  • code/addons/vitest/src/postinstall.ts
  • code/lib/cli-storybook/src/warn.ts
📚 Learning: 2025-11-05T09:37:25.920Z
Learnt from: Sidnioulz
Repo: storybookjs/storybook PR: 32458
File: code/core/src/components/components/tooltip/WithTooltip.tsx:54-96
Timestamp: 2025-11-05T09:37:25.920Z
Learning: Repo: storybookjs/storybook — In code/core/src/components/components/tooltip/WithTooltip.tsx, the legacy WithTooltip implementation is intentionally reintroduced for backward compatibility and is deprecated; maintainers (per Sidnioulz) do not want maintenance or improvements on it. Prefer WithTooltipNew/Popover; avoid suggesting changes to WithTooltip.* going forward.

Applied to files:

  • code/core/src/manager/components/mobile/about/MobileAbout.tsx
  • code/lib/cli-storybook/src/codemod/csf-factories.ts
  • code/builders/builder-webpack5/src/types.ts
  • code/frameworks/angular/template/stories/others/ngx-translate/README.mdx
  • code/lib/cli-storybook/src/warn.ts
📚 Learning: 2025-11-28T14:50:24.889Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Follow existing patterns and conventions in the Storybook codebase

Applied to files:

  • code/core/src/manager/components/mobile/about/MobileAbout.tsx
  • code/lib/cli-storybook/src/codemod/csf-factories.ts
  • code/frameworks/nextjs-vite/README.md
  • code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts
  • code/frameworks/angular/template/stories/others/ngx-translate/README.mdx
📚 Learning: 2025-11-24T17:49:31.838Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .cursorrules:0-0
Timestamp: 2025-11-24T17:49:31.838Z
Learning: Applies to code/vitest.workspace.ts : Vitest configuration is centralized in `code/vitest.workspace.ts` for workspace setup

Applied to files:

  • code/core/src/server-errors.ts
  • code/addons/vitest/src/preset.ts
  • code/addons/vitest/src/postinstall.ts
📚 Learning: 2025-11-24T17:49:59.279Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .cursor/rules/spy-mocking.mdc:0-0
Timestamp: 2025-11-24T17:49:59.279Z
Learning: Applies to **/*.test.{ts,tsx,js,jsx} : Document complex mock behaviors in Vitest tests

Applied to files:

  • code/core/src/server-errors.ts
  • code/renderers/react/src/entry-preview.tsx
  • code/addons/vitest/src/preset.ts
  • code/frameworks/react-vite/src/types.ts
  • code/builders/builder-webpack5/src/types.ts
📚 Learning: 2025-11-24T17:49:59.279Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .cursor/rules/spy-mocking.mdc:0-0
Timestamp: 2025-11-24T17:49:59.279Z
Learning: Applies to **/*.test.{ts,tsx,js,jsx} : Avoid mocking only a subset of required dependencies in Vitest tests

Applied to files:

  • code/core/src/server-errors.ts
  • code/addons/vitest/src/preset.ts
  • code/core/src/core-server/presets/common-preset.ts
📚 Learning: 2025-11-24T17:49:59.279Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .cursor/rules/spy-mocking.mdc:0-0
Timestamp: 2025-11-24T17:49:59.279Z
Learning: Applies to **/*.test.{ts,tsx,js,jsx} : Avoid mocking without the `spy: true` option in Vitest tests

Applied to files:

  • code/core/src/server-errors.ts
📚 Learning: 2025-11-28T14:50:24.889Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to README.md : Update relevant README files for significant code changes

Applied to files:

  • code/lib/cli-storybook/src/codemod/csf-factories.ts
  • code/frameworks/nextjs-vite/README.md
  • code/frameworks/angular/template/stories/others/ngx-translate/README.mdx
📚 Learning: 2025-10-01T15:24:01.060Z
Learnt from: Sidnioulz
Repo: storybookjs/storybook PR: 32594
File: code/core/src/components/components/Popover/WithPopover.tsx:7-9
Timestamp: 2025-10-01T15:24:01.060Z
Learning: In the Storybook repository, "react-aria-components/patched-dist/*" (e.g., "react-aria-components/patched-dist/Dialog", "react-aria-components/patched-dist/Popover", "react-aria-components/patched-dist/Tooltip") are valid import paths created by a patch applied to the react-aria-components package. These imports should not be flagged as broken or invalid until a maintainer explicitly states they are no longer acceptable.

Applied to files:

  • code/lib/cli-storybook/src/codemod/csf-factories.ts
📚 Learning: 2025-09-18T20:51:06.618Z
Learnt from: Sidnioulz
Repo: storybookjs/storybook PR: 32458
File: code/core/src/viewport/components/Tool.tsx:38-39
Timestamp: 2025-09-18T20:51:06.618Z
Learning: The useGlobals hook from storybook/manager-api returns a tuple where the third element (storyGlobals) is typed as Globals, not Globals | undefined. This means TypeScript guarantees it's always defined, making the `in` operator safe to use without additional null checks.

Applied to files:

  • code/renderers/react/src/entry-preview.tsx
📚 Learning: 2025-11-24T17:49:59.279Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .cursor/rules/spy-mocking.mdc:0-0
Timestamp: 2025-11-24T17:49:59.279Z
Learning: Applies to **/*.test.{ts,tsx,js,jsx} : Avoid mock implementations outside of `beforeEach` blocks in Vitest tests

Applied to files:

  • code/renderers/react/src/entry-preview.tsx
  • code/core/src/core-server/presets/common-preset.ts
📚 Learning: 2025-11-28T14:50:24.889Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to code/**/*.{test,spec}.{ts,tsx,js,jsx} : Write meaningful unit tests that actually import and call the functions being tested

Applied to files:

  • code/renderers/react/src/entry-preview.tsx
📚 Learning: 2025-11-24T17:49:59.279Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .cursor/rules/spy-mocking.mdc:0-0
Timestamp: 2025-11-24T17:49:59.279Z
Learning: Applies to **/*.test.{ts,tsx,js,jsx} : Implement mock behaviors in `beforeEach` blocks in Vitest tests

Applied to files:

  • code/renderers/react/src/entry-preview.tsx
  • code/core/src/core-server/presets/common-preset.ts
📚 Learning: 2025-09-18T20:51:06.618Z
Learnt from: Sidnioulz
Repo: storybookjs/storybook PR: 32458
File: code/core/src/viewport/components/Tool.tsx:38-39
Timestamp: 2025-09-18T20:51:06.618Z
Learning: In viewport tool code, when using the `useGlobals` hook from storybook/manager-api, the third returned value `storyGlobals` is guaranteed by TypeScript to be defined (not undefined/null), making the `in` operator safe to use without additional null checks.

Applied to files:

  • code/renderers/react/src/entry-preview.tsx
📚 Learning: 2025-11-24T17:49:59.279Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .cursor/rules/spy-mocking.mdc:0-0
Timestamp: 2025-11-24T17:49:59.279Z
Learning: Applies to **/*.test.{ts,tsx,js,jsx} : Avoid inline mock implementations within test cases in Vitest tests

Applied to files:

  • code/renderers/react/src/entry-preview.tsx
  • code/addons/vitest/src/preset.ts
📚 Learning: 2025-11-28T14:50:24.889Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to code/**/*.{ts,tsx,js,jsx} : Export functions that need to be tested from their modules

Applied to files:

  • code/renderers/react/src/entry-preview.tsx
📚 Learning: 2025-11-24T17:49:59.279Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .cursor/rules/spy-mocking.mdc:0-0
Timestamp: 2025-11-24T17:49:59.279Z
Learning: Applies to **/*.test.{ts,tsx,js,jsx} : Keep mock implementations simple and focused in Vitest tests

Applied to files:

  • code/addons/vitest/src/preset.ts
📚 Learning: 2025-11-28T14:50:24.889Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to docs/**/migration*.md : Update migration guides for breaking changes

Applied to files:

  • code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts
📚 Learning: 2025-11-28T14:50:24.889Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to code/**/*.{ts,tsx,js,jsx,mjs} : Use server-side logger from 'storybook/internal/node-logger' for Node.js code

Applied to files:

  • code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts
  • code/core/src/core-server/utils/StoryIndexGenerator.ts
  • code/lib/cli-storybook/src/warn.ts
📚 Learning: 2025-09-24T13:04:58.631Z
Learnt from: cylewaitforit
Repo: storybookjs/storybook PR: 31965
File: code/lib/eslint-plugin/src/rules/only-csf3.ts:31-33
Timestamp: 2025-09-24T13:04:58.631Z
Learning: The Storybook ESLint plugin supports ESLint v8.57+ where context.sourceCode is already available as a property since it was introduced in v8.40.0, so no fallback to context.getSourceCode() is needed in rules.

Applied to files:

  • code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts
📚 Learning: 2025-11-28T14:50:24.889Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to code/**/*.{js,jsx,json,html,ts,tsx,mjs} : Run ESLint with yarn lint:js:cmd to check for linting issues and fix errors before committing

Applied to files:

  • code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts
📚 Learning: 2025-11-28T14:50:24.889Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to code/**/*.{ts,tsx,js,jsx,mjs} : Use client-side logger from 'storybook/internal/client-logger' for browser code

Applied to files:

  • code/core/src/core-server/utils/StoryIndexGenerator.ts
  • code/lib/cli-storybook/src/warn.ts
📚 Learning: 2025-11-28T14:50:24.889Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to code/**/*.{ts,tsx,js,jsx,mjs} : Do not use console.log, console.warn, or console.error directly unless in isolated files where importing loggers would significantly increase bundle size

Applied to files:

  • code/core/src/core-server/utils/StoryIndexGenerator.ts
  • code/lib/cli-storybook/src/warn.ts
📚 Learning: 2025-11-05T09:36:55.944Z
Learnt from: Sidnioulz
Repo: storybookjs/storybook PR: 32458
File: code/core/src/components/components/Tabs/Tabs.stories.tsx:222-227
Timestamp: 2025-11-05T09:36:55.944Z
Learning: Repo: storybookjs/storybook PR: 32458 — In code/core/src/components/components/Button/Button.tsx (React/TypeScript), ButtonProps includes ariaLabel?: string | false and the component maps it to the DOM aria-label. Convention: ariaLabel is mandatory on all Button usages — provide a descriptive string for icon-only buttons; set ariaLabel=false when the button’s children already serve as the accessible name. Do not suggest using a raw aria-label prop on Button call sites.

Applied to files:

  • code/core/src/controls/types.ts
📚 Learning: 2025-09-24T09:39:39.233Z
Learnt from: ndelangen
Repo: storybookjs/storybook PR: 32507
File: code/core/src/manager/globals/globals-module-info.ts:25-33
Timestamp: 2025-09-24T09:39:39.233Z
Learning: In Storybook, storybook/actions/decorator is a preview-only entrypoint and should not be included in manager globals configuration. The duplicatedKeys array in code/core/src/manager/globals/globals-module-info.ts is specifically for manager-side externalization, not preview entrypoints.

Applied to files:

  • code/frameworks/angular/template/stories/others/ngx-translate/README.mdx
📚 Learning: 2025-11-28T14:50:24.889Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.889Z
Learning: Applies to **/*.{ts,tsx} : Enable TypeScript strict mode

Applied to files:

  • code/lib/cli-storybook/src/warn.ts
🧬 Code graph analysis (2)
code/lib/cli-storybook/src/codemod/csf-factories.ts (1)
scripts/utils/tools.ts (1)
  • picocolors (118-118)
code/addons/vitest/src/postinstall.ts (1)
code/addons/vitest/src/constants.ts (1)
  • DOCUMENTATION_LINK (16-16)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: nx
🔇 Additional comments (35)
code/frameworks/angular/template/stories/others/ngx-translate/README.mdx (1)

12-12: Documentation link updated to generic pattern with renderer parameter.

The link has been updated from an Angular-specific documentation path to the generic decorators documentation with a ?renderer=angular query parameter. This aligns with the PR's objective to modernize documentation references and prevent 404s.

Please confirm that the URL structure https://storybook.js.org/docs/writing-stories/decorators?renderer=angular is consistent with how Storybook's documentation currently handles framework-specific routing for generic documentation pages across the PR's other URL updates.

code/addons/a11y/src/types.ts (1)

27-27: Documentation link update looks good.

The anchor fragment update from #turn-off-automated-a11y-tests to #disable-automated-checks aligns with the PR objectives to reflect the latest documentation structure. The comment accurately describes the feature, and the URL path remains consistent with other accessibility testing documentation links in the codebase.

code/core/src/manager/components/mobile/about/MobileAbout.tsx (1)

64-64: Docs link normalization looks good

The updated href to https://storybook.js.org/docs/get-started/install?ref=ui matches the current docs route pattern and removes the extra trailing slash while preserving tracking. No behavioral impact on the component and consistent with nearby external links.

code/core/src/backgrounds/types.ts (1)

31-36: Clarified backgrounds.disable docs look good

The expanded description and @see link clearly explain both per-story and global configuration without affecting types.

code/core/src/cli/eslintPlugin.ts (1)

258-263: ESLint plugin prompt URL update is consistent

The prompt message and highlighting remain intact, and the URL now points at the updated integration docs path.

code/core/src/controls/types.ts (1)

8-14: Improved controls.disable documentation reads clearly

The new description correctly explains disabling the panel vs. global config and points to the appropriate docs section.

code/renderers/react/src/entry-preview.tsx (1)

33-37: Updated experimental test syntax docs anchor is appropriate

The runtime error still accurately describes the feature flag and now links to the updated docs fragment for experimentalTestSyntax.

code/lib/cli-storybook/src/warn.ts (1)

18-24: TypeScript guidance URL points to updated integration docs

The logging flow is unchanged, and the info message now directs users to the newer TypeScript integration page while still using the internal logger per guidelines.

code/core/src/core-server/presets/common-preset.ts (1)

111-113: Babel override comment now references the precise docs section

The rationale for the override is unchanged, and the URL now points to the more specific interaction-testing section about running code before each story.

code/lib/create-storybook/src/commands/AddonConfigurationCommand.ts (1)

11-14: Vitest addon manual-setup link targets advanced section appropriately

The instruction map is intact and now routes users directly to the advanced manual setup subsection, which is appropriate for failed auto-configuration.

code/frameworks/angular/src/client/public-types.ts (1)

20-48: Angular public types now reference CSF API docs correctly

The @see links for Meta, StoryFn, and StoryObj all point to the CSF API documentation with the right anchors, improving discoverability without changing typings.

code/core/src/highlight/types.ts (1)

14-19: LGTM! Documentation enhancement is clear and helpful.

The expanded JSDoc provides better guidance on how to disable the highlight feature globally via configuration. This aligns with similar improvements made to other feature types in this PR.

code/builders/builder-webpack5/src/types.ts (1)

37-37: LGTM! Documentation link updated to current structure.

The URL update removes the version-specific path and normalizes the anchor fragment, aligning with the updated documentation structure.

code/core/src/outline/types.ts (1)

8-13: LGTM! Consistent documentation improvement.

The expanded JSDoc follows the same helpful pattern used in other feature types (highlight, measure), providing clear guidance on disabling the feature.

code/core/src/measure/types.ts (1)

8-13: LGTM! Consistent documentation pattern.

The JSDoc expansion matches the pattern used in highlight and outline types, maintaining consistency across the codebase.

code/addons/vitest/src/postinstall.ts (3)

167-167: LGTM! Error message documentation link updated.

The URL now points to the advanced manual setup section, providing more specific guidance for users encountering this error.


259-259: LGTM! Consistent documentation link updates.

All error messages now consistently reference the #manual-setup-advanced section, providing users with more detailed setup instructions when automated configuration fails.

Also applies to: 307-307, 393-393


368-368: LGTM! a11y integration documentation link updated.

The URL now points to the updated location for accessibility testing integration documentation.

code/lib/cli-storybook/src/codemod/csf-factories.ts (2)

65-65: LGTM! Documentation link updated to CSF Next docs.

The URL now points directly to the CSF Next documentation with a specific anchor for the previewmeta section, providing more relevant guidance.


120-120: LGTM! Documentation link updated with ref tracking.

The URL now includes a ref=upgrade parameter which helps track documentation traffic from upgrade flows while pointing to the current docs structure.

code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts (1)

47-47: LGTM! Warning message documentation link updated.

The URL anchor is updated to match the current documentation structure, ensuring users get accurate guidance when this warning is triggered.

code/core/src/preview-api/modules/preview-web/parseArgsParam.ts (1)

117-117: LGTM! Warning message documentation link normalized.

The URL structure is now standardized with the query parameter before the fragment anchor, following typical URL conventions.

code/addons/vitest/src/preset.ts (1)

71-75: LGTM!

The log message updates are appropriate:

  • The addon naming is now consistent with "Storybook's Vitest addon"
  • The documentation URL correctly points to the Next.js + Vite framework page with the relevant anchor section for users to understand the Vite vs Webpack choice
code/core/src/actions/types.ts (1)

22-29: LGTM!

The JSDoc update provides clearer guidance for the disable property, including how to configure it project-wide via main.js|ts, and the updated @see link points to the appropriate documentation section.

code/frameworks/nextjs-vite/src/types.ts (1)

42-47: LGTM!

The @see link correctly points to the Next.js with Vite framework documentation, which is the appropriate reference for this nextjs-vite framework types file.

code/frameworks/react-vite/src/types.ts (1)

44-51: LGTM!

The @see link update provides a direct reference to the experimentalTestSyntax feature documentation in the main-config-features API section.

code/frameworks/nextjs-vite/README.md (1)

3-3: LGTM!

The documentation link correctly points to the Next.js with Vite framework page, consistent with the types.ts update in the same package. The query parameters provide appropriate context for the docs page.

code/core/src/server-errors.ts (3)

377-377: LGTM! Improved accuracy by referencing both file extensions.

The helper messages have been updated to reference "main.js|ts" instead of just "main.js", which is more accurate since Storybook supports both JavaScript and TypeScript configuration files.

Also applies to: 382-382, 395-395


312-312: Documentation link correctly updated to accessible Next.js font optimization guidance.

The URL at line 312 points to the appropriate Next.js-specific font optimization documentation (HTTP 200 verified) and is contextually correct for the GoogleFontsDownloadError class category.


492-492: Documentation links correctly point to Vitest addon manual setup (advanced) section.

All three error scenarios (codes 7, 8, 9) reference the appropriate documentation section for manual Vitest setup, which covers handling existing setup files and manual configuration. The URL and anchor are valid and accessible.

code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts (1)

142-142: LGTM! Documentation link updated appropriately.

The URL has been updated to point to the Next.js + Vite framework documentation, which is appropriate for this migration context. The URL is accessible and correctly directs users to the relevant Storybook documentation for the @storybook/nextjs-vite framework.

code/core/src/preview-errors.ts (1)

321-322: LGTM! Documentation link updated to specific error guidance.

The URL points to a specific section in the Next.js framework documentation, providing targeted guidance for AVIF image import issues. The link is accessible and properly formatted.

code/core/src/viewport/types.ts (1)

38-41: LGTM! JSDoc documentation improved and URL verified.

The documentation uses improved terminology ("tool" and "feature") and correctly references both "main.js|ts" configuration file options. The documentation URL at https://storybook.js.org/docs/essentials/viewport#disable is accessible and accurate.

code/lib/cli-storybook/src/automigrate/fixes/eslint-plugin.ts (1)

27-27: LGTM! Version-agnostic documentation link.

The URL is version-agnostic and accessible, correctly updated as part of the link fixes in the codebase.

code/core/src/core-server/utils/StoryIndexGenerator.ts (1)

619-621: LGTM! MDX2 migration guidance updated.

The URL correctly points to the MDX2 upgrade section in the MIGRATION.md file, providing users with detailed migration guidance.


Comment @coderabbitai help to get the list of available commands and usage tips.

@jonniebigodes jonniebigodes merged commit 0918cb5 into next Dec 15, 2025
14 checks passed
@jonniebigodes jonniebigodes deleted the fix_outdated_docs_references_codebase branch December 15, 2025 16:36
@github-actions github-actions bot mentioned this pull request Dec 17, 2025
18 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:docs Run the CI jobs for documentation checks only. documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants