Skip to content

Docs: Convert all main.* and preview.* references to linked .* notation#34459

Draft
Copilot wants to merge 2 commits intonextfrom
copilot/convert-main-preview-references-to-links
Draft

Docs: Convert all main.* and preview.* references to linked .* notation#34459
Copilot wants to merge 2 commits intonextfrom
copilot/convert-main-preview-references-to-links

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 3, 2026

Using specific extensions like preview.ts or main.js implies those files must use that language. All doc references should use .* to signal extension-agnosticism, and link to the reference pages where allowed extensions are documented explicitly.

Changes

  • Text references (outside code blocks): All preview.js, preview.ts, preview.js|ts, .storybook/preview.tsx, etc. → [`.storybook/preview.*`](configure/index.mdx#configure-story-rendering) with correct relative links per file location
  • Same for main.*: All variants → [`.storybook/main.*`](api/main-config/main-config.mdx)
  • Code block titles: Pipe-separated title=".storybook/main.js|ts" → single extension matching the fence language (e.g. ```ts title=".storybook/main.ts")
  • main.js|ts configuration sidebar/page titles in API docs → main.* configuration
  • Headings: Use .* notation, no link (per issue guidance)

Intentionally preserved

  • Framework-internal preview.js references in contribute/framework.mdx and api/new-frameworks.mdx (not the user-facing config file)
  • The rename instruction in builders/vite.mdx: "Rename .storybook/main.js to .storybook/main.ts" — the JS→TS distinction is the entire point of that sentence

- Convert all text references in docs MDX files from specific extensions
  (preview.ts, preview.tsx, preview.js, preview.jsx, main.ts, main.js, etc.)
  to .* notation with links to the reference pages
- preview.* links point to configure/index.mdx#configure-story-rendering
- main.* links point to api/main-config/main-config.mdx
- Code block titles updated from pipe-separated (|ts) to single specific
  extensions based on fence language
- main.js|ts configuration titles updated to main.* configuration
- Headings use .* notation without links per issue requirements

Agent-Logs-Url: https://github.com/storybookjs/storybook/sessions/73433770-3447-46fc-a0e9-9c8ef433f3a6

Co-authored-by: Sidnioulz <5108577+Sidnioulz@users.noreply.github.com>
Copilot AI changed the title [WIP] Update documentation to link references for main and preview files Docs: Convert all main.* and preview.* references to linked .* notation Apr 3, 2026
Copilot AI requested a review from Sidnioulz April 3, 2026 16:10
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.

Docs: Convert all references to main.* and preview.* to links

3 participants