Skip to content

Conversation

@JReinhold
Copy link
Contributor

@JReinhold JReinhold commented Nov 28, 2025

Follow up to #33194

What I did

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
    • Rewrote repository guidance to adopt an NX-centric workflow and external sandbox locations; updated install, compile, test, and troubleshooting guidance.
  • Chores
    • Added a GitHub Actions workflow to automate setup and compile steps.
    • Removed obsolete steering and product guidance documents.

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

@JReinhold JReinhold requested a review from Copilot November 28, 2025 20:56
@JReinhold JReinhold self-assigned this Nov 28, 2025
@JReinhold JReinhold added build Internal-facing build tooling & test updates ci:docs Run the CI jobs for documentation checks only. labels Nov 28, 2025
Copilot finished reviewing on behalf of JReinhold November 28, 2025 20:58
@nx-cloud
Copy link

nx-cloud bot commented Nov 28, 2025

View your CI Pipeline Execution ↗ for commit a75504b

Command Status Duration Result
nx run-many -t compile --parallel=3 ✅ Succeeded 6s View ↗

☁️ Nx Cloud last updated this comment at 2025-11-28 21:23:14 UTC

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 28, 2025

📝 Walkthrough

Walkthrough

The PR updates Copilot instructions to adopt NX as the primary task runner, revises the repository layout and sandboxing guidance, adds a new GitHub Actions workflow for Copilot setup steps, and removes three steering documentation files (.kiro/steering/*).

Changes

Cohort / File(s) Summary
Copilot Configuration
/.github/copilot-instructions.md
Major rewrite to emphasize NX: repository overview (git root, code/, scripts/), add .nx/ and external sandbox path (../storybook-sandboxes/), convert command examples to yarn nx patterns, expand NX section (concepts, commands, caching, dep management), reorganize Installation/Compilation/Lint/Test/Watch/Dev server sections, update sandboxing templates and warnings, and small stylistic edits.
GitHub Actions
/.github/workflows/copilot-setup-steps.yml
New workflow "Copilot Setup Steps" triggered on workflow_dispatch, push, and pull_request (workflow path). Job copilot-setup-steps runs on ubuntu-latest, checks out code, uses local ./.github/actions/setup-node-and-install action with install-code-deps: true, and runs yarn nx run-many --targets compile.
Deleted Steering Documentation
.kiro/steering/product.md, .kiro/steering/structure.md, .kiro/steering/tech.md
Removed three steering docs: product.md (Storybook product overview/features/targets), structure.md (monorepo layout, package conventions, workflows, examples), and tech.md (technology stack, build/test commands, framework support). No code/entity signatures changed.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

  • Review .github/copilot-instructions.md thoroughly for accuracy of NX commands, workspace paths, and sandboxing instructions.
  • Verify .github/workflows/copilot-setup-steps.yml action path, checkout ref usage, and yarn nx invocation correctness.
  • Confirm the deletions in .kiro/steering/* are intentional and that any needed guidance has been migrated or archived.

📜 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 5e3e8c3 and a75504b.

📒 Files selected for processing (1)
  • .github/workflows/copilot-setup-steps.yml (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • .github/workflows/copilot-setup-steps.yml
⏰ 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). (3)
  • GitHub Check: Core Unit Tests, windows-latest
  • GitHub Check: copilot-setup-steps
  • GitHub Check: copilot-setup-steps

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

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (2)
.github/copilot-instructions.md (2)

175-175: Fix bare URL by wrapping in angle brackets for markdown compliance.

Line 175 contains a bare URL that should be wrapped in angle brackets to comply with markdown linting standards (MD034).

Apply this diff to fix the bare URL:

- Access at http://localhost:6006/
+ Access at <http://localhost:6006/>

263-263: Fix bare URL by wrapping in angle brackets for markdown compliance.

Line 263 contains a bare URL that should be wrapped in angle brackets to comply with markdown linting standards (MD034).

Apply this diff to fix the bare URL:

- Access at http://localhost:6006/ to test your changes
+ Access at <http://localhost:6006/> to test your changes
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 013a3d9 and 5e3e8c3.

📒 Files selected for processing (5)
  • .github/copilot-instructions.md (9 hunks)
  • .github/workflows/copilot-setup-steps.yml (1 hunks)
  • .kiro/steering/product.md (0 hunks)
  • .kiro/steering/structure.md (0 hunks)
  • .kiro/steering/tech.md (0 hunks)
💤 Files with no reviewable changes (3)
  • .kiro/steering/structure.md
  • .kiro/steering/tech.md
  • .kiro/steering/product.md
🧰 Additional context used
🧠 Learnings (24)
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
Learning: Applies to README.md : Update relevant README files for significant code changes

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
Learning: Follow existing patterns and conventions in the Storybook codebase

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2025-10-02T09:22:13.215Z
Learnt from: JReinhold
Repo: storybookjs/storybook PR: 32607
File: code/package.json:243-243
Timestamp: 2025-10-02T09:22:13.215Z
Learning: The Storybook repository uses Yarn v^4 (any 4.x version) as the package manager, configured via .yarnrc.yml and package.json packageManager field. Specific patch versions within v4 can be upgraded as needed.

Applied to files:

  • .github/copilot-instructions.md
📚 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:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
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:

  • .github/copilot-instructions.md
📚 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: Tests are located in the `code/` directory with root directory for test execution at `./code/`

Applied to files:

  • .github/copilot-instructions.md
📚 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:

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

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2025-09-17T07:31:04.432Z
Learnt from: ndelangen
Repo: storybookjs/storybook PR: 32484
File: code/core/package.json:326-326
Timestamp: 2025-09-17T07:31:04.432Z
Learning: In Storybook's core package, dependencies like `open` are bundled into the final distribution during the build process, so they should remain in devDependencies rather than being moved to dependencies. End users don't need these packages as separate runtime dependencies since they're included in the bundled code.

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2025-09-29T13:20:23.346Z
Learnt from: mrginglymus
Repo: storybookjs/storybook PR: 32556
File: code/core/package.json:309-313
Timestamp: 2025-09-29T13:20:23.346Z
Learning: The `fast-printf` dependency in Storybook's core package is bundled into the final distribution during the build process, so it should remain in devDependencies rather than being moved to dependencies, following the same pattern as other bundled dependencies like `open`.

Applied to files:

  • .github/copilot-instructions.md
📚 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:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
Learning: Use Yarn 4.9.1 as the package manager

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
Learning: Applies to code/**/*.{test,spec}.{ts,tsx,js,jsx} : Aim for high test coverage of business logic (75%+ for statements/lines) using coverage reports

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
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:

  • .github/copilot-instructions.md
📚 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:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
Learning: Applies to code/**/*.{test,spec}.{ts,tsx,js,jsx} : Mock external dependencies using vi.mock() for file system, loggers, and other external dependencies in tests

Applied to files:

  • .github/copilot-instructions.md
📚 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 **/*.{test,spec}.{ts,tsx} : Follow the spy mocking rules defined in `.cursor/rules/spy-mocking.mdc` for consistent mocking patterns with Vitest

Applied to files:

  • .github/copilot-instructions.md
📚 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:

  • .github/copilot-instructions.md
📚 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 **/*.{test,spec}.{ts,tsx} : Test files should follow the naming pattern `*.test.ts`, `*.test.tsx`, `*.spec.ts`, or `*.spec.tsx`

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
Learning: Applies to **/*.{js,jsx,json,html,ts,tsx,mjs} : Use ESLint and Prettier configurations that are enforced in the codebase

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
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:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
Learning: Applies to code/**/*.{js,jsx,json,html,ts,tsx,mjs} : Run Prettier with --write flag to format code before committing

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
Learning: Applies to code/{addons,frameworks}/**/README.md : Include code examples in addon/framework documentation for significant changes

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2025-11-28T14:50:24.872Z
Learnt from: CR
Repo: storybookjs/storybook PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-28T14:50:24.872Z
Learning: Ensure all builds and tests pass before submitting pull requests

Applied to files:

  • .github/copilot-instructions.md
🪛 LanguageTool
.github/copilot-instructions.md

[grammar] ~177-~177: Ensure spelling is correct
Context: ...cess at http://localhost:6006/ ### For Addon/Framework/Renderers Development 1. Nav...

(QB_NEW_EN_ORTHOGRAPHY_ERROR_IDS_1)

🪛 markdownlint-cli2 (0.18.1)
.github/copilot-instructions.md

175-175: Bare URL used

(MD034, no-bare-urls)


263-263: Bare URL used

(MD034, no-bare-urls)

⏰ 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). (2)
  • GitHub Check: Core Unit Tests, windows-latest
  • GitHub Check: copilot-setup-steps
🔇 Additional comments (8)
.github/workflows/copilot-setup-steps.yml (3)

30-31: Verify that the NX compile command includes the -c production flag if required for setup steps.

According to the copilot-instructions.md (line 123), the -c production flag is documented as "required" for sandbox-related commands. Confirm whether this flag should also be included in the setup-steps workflow's compile command, or if it's only required for sandbox generation tasks.


26-28: Verify that the custom action at ./.github/actions/setup-node-and-install exists and is accessible.

The workflow references a custom action that sets up Node.js and installs dependencies. Ensure this action is available in the repository at the referenced path.


14-31: Workflow structure aligns with Copilot agent requirements.

The job is correctly named copilot-setup-steps to be picked up by Copilot, triggers are appropriately scoped to the workflow file itself (avoiding unnecessary runs), and the step sequence (checkout → setup → compile) follows best practices for CI workflows.

.github/copilot-instructions.md (5)

177-179: Verify spelling and wording in framework development section.

Line 177 flags an orthography concern. Review the section heading for potential spelling or grammatical issues. The current text reads "### For Addon/Framework/Renderers Development" which appears correct, but ensure consistency with terminology used elsewhere in the document.


101-127: Comprehensive NX documentation provides excellent guidance.

The NX Task Runner section clearly explains concepts, provides command equivalents, highlights the -c production requirement, and demonstrates practical usage patterns. This section effectively bridges between legacy yarn task commands and modern NX equivalents.


7-8: Repository structure and NX guidance are clearly documented.

The document effectively communicates the monorepo layout (git root as monorepo root with code/ and scripts/ split), updated NX-centric task orchestration, and the critical sandbox location change outside the repository. The progression from structure overview through detailed NX concepts to practical examples provides both clarity and actionable guidance.

Also applies to: 17-35, 101-127


375-399: Logger guidance accurately reflects Storybook conventions.

The logging section comprehensively documents the distinction between server-side (storybook/internal/node-logger) and client-side (storybook/internal/client-logger) loggers with clear examples. The explicit warning against direct console usage (line 399) is important for maintaining code quality.


208-264: Sandbox documentation is comprehensive and emphasizes important location changes.

The repeated references to the ../storybook-sandboxes/ location (lines 34, 137, 212, 252-253, 325-326) appropriately highlight this significant change. The explanation of the distinction between this external location, the internal ./sandbox NX outputs directory, and the workaround for when sandbox generation fails provides practical guidance.

Copy link
Contributor

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.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

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

Labels

build Internal-facing build tooling & test updates ci:docs Run the CI jobs for documentation checks only.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants