Skip to content

Docs: Fix incorrect value for includePrimary in documentation#34792

Merged
Sidnioulz merged 2 commits into
storybookjs:nextfrom
NlDev-hub:docs/fix-stories-include-primary-note
Jun 18, 2026
Merged

Docs: Fix incorrect value for includePrimary in documentation#34792
Sidnioulz merged 2 commits into
storybookjs:nextfrom
NlDev-hub:docs/fix-stories-include-primary-note

Conversation

@NlDev-hub

@NlDev-hub NlDev-hub commented May 13, 2026

Copy link
Copy Markdown
Contributor

Fixes #24167.

The Stories docs currently say a single-story file renders nothing when includePrimary={true}. The current block implementation only omits the primary story when includePrimary={false}, and then returns nothing if no stories remain.

This updates the note to match that behavior.

Checks:

  • Ran git diff --check
  • Independently reviewed the docs-only diff against the implementation

Note: I could not run the repo formatter locally because yarn/corepack were unavailable in my environment.

Manual testing

Open documentation site on local branch and see changes. N/A.

Summary by CodeRabbit

  • Documentation
    • Improved Stories block documentation with clearer guidance on the includePrimary prop behavior and empty-render scenarios.

Review Change Stack

@coderabbitai

coderabbitai Bot commented May 13, 2026

Copy link
Copy Markdown
Contributor

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: be57ace4-492d-4f85-b69b-4bd1140ee651

📥 Commits

Reviewing files that changed from the base of the PR and between 589f29c and 193986d.

📒 Files selected for processing (1)
  • docs/api/doc-blocks/doc-block-stories.mdx

📝 Walkthrough

Walkthrough

The Stories block documentation for the includePrimary prop is updated to explicitly clarify the behavior when set to false and to note that the block renders nothing when the primary story is the only story in the file.

Changes

Stories Block Documentation

Layer / File(s) Summary
includePrimary prop documentation
docs/api/doc-blocks/doc-block-stories.mdx
Documentation text for the includePrimary prop is clarified to describe the behavior when includePrimary={false} and the edge case where the block renders empty when the primary story is the sole story.

🎯 1 (Trivial) | ⏱️ ~2 minutes

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@valentinpalkovic

Copy link
Copy Markdown
Contributor

Hi @NlDev-hub,

Due to a recent high volume of unreviewed AI-generated PRs, we are requesting verification and proof that the implemented fix actually works. Please provide a simple GIF/Video or image of how the fix works, optimally with before-and-after comparisons.

Thank you for your understanding!

@valentinpalkovic valentinpalkovic moved this to Human verification in Core Team Projects May 18, 2026
@jonniebigodes jonniebigodes self-assigned this May 18, 2026
@NlDev-hub

Copy link
Copy Markdown
Contributor Author

Thanks for checking. I verified the PR locally against docs/api/doc-blocks/doc-block-stories.mdx at base 589f29c and PR head 193986d.

The change is documentation-only. Before, the note said the empty-render case happened with includePrimary={true}. After this PR, it documents the actual behavior: includePrimary={false} omits the primary story, and if that primary story is the only story in the file, the Stories block renders nothing.

Before/after proof of the exact changed docs section:

Before/after docs proof for PR #34792

@github-actions github-actions Bot added the Stale label Jun 3, 2026
@Sidnioulz Sidnioulz closed this Jun 8, 2026
@github-project-automation github-project-automation Bot moved this from Human verification to Done in Core Team Projects Jun 8, 2026
@Sidnioulz Sidnioulz reopened this Jun 8, 2026
@Sidnioulz Sidnioulz closed this Jun 12, 2026
@Sidnioulz

Copy link
Copy Markdown
Contributor

Sorry about that, my triage script got a little too eager.

@Sidnioulz Sidnioulz reopened this Jun 12, 2026
@Sidnioulz Sidnioulz added ci:docs Run the CI jobs for documentation checks only. qa:skip Pull Requests that do not need any QA. and removed Stale labels Jun 12, 2026
@Sidnioulz Sidnioulz changed the title docs: fix Stories includePrimary note Docs: Fix incorrect value for includePrimary in documentation Jun 12, 2026

@jonniebigodes jonniebigodes left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@NlDev-hub thanks for taking the time to put together this pull request and helping us improve the documentation. I've checked it and all looks good on my end.

Will gladly merge this once the checklist clears

Have a great day.

Stay safe

@Sidnioulz Sidnioulz merged commit d2400da into storybookjs:next Jun 18, 2026
13 of 14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent-scan:human ci:docs Run the CI jobs for documentation checks only. documentation qa:skip Pull Requests that do not need any QA. verification:success

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

[Documentation]: includePrimary note in Stories doc block is incorrect

4 participants