Skip to content

docs: offer npm/yarn/bun for every install command (#402) - #453

Merged
allxsmith merged 1 commit into
mainfrom
docs/pm-tabs-rollout
Aug 2, 2026
Merged

allxsmith merged 1 commit into
mainfrom
docs/pm-tabs-rollout

Conversation

@allxsmith

Copy link
Copy Markdown
Owner

Pull Request

Description

Wraps 46 command blocks across 12 guides in <PackageManagerTabs>, so readers on npm, yarn
or bun stop translating pnpm commands by hand. The component derives the other three from the
authored pnpm fence, and the shared tab group means a choice made on one page — or in the
homepage hero from #434 — is already selected everywhere else.

Fixes a live error on the way

installation.md had three hand-written sections:

  • ### Using npm (recommended) sitting above a pnpm add command
  • a ### Using pnpm section that was a byte-for-byte duplicate of it
  • no bun at all

So the page told npm readers to run pnpm. All three collapse into one component that renders
the correct command per manager. No inbound links referenced the removed anchors (checked
across docs/, skills/, the packages and the README).

Four commands rewritten into the authoring vocabulary

The component authors in pnpm's verb vocabulary and derives the rest, so these had to move into
it. The only visible change for pnpm readers is pnpm dev → the equivalent pnpm run dev:

before after
pnpm dev pnpm run dev 7 blocks
npm start pnpm run start 2 blocks, CRA setups
npm install -D @fullhuman/postcss-purgecss pnpm add -D …
npm uninstall node-sass pnpm remove …

Deliberately not converted

Worth reading, because two of these are correctness constraints rather than taste:

  • contributing.md (9 blocks). These are monorepo commands — pnpm exec, --filter,
    audit, approve-builds, why — which aren't package-manager verbs, so the round-trip
    assertion rejects them and the build fails. I verified this:

    FAILS "pnpm exec turbo run build"             -> "exec turbo run build"
    FAILS "pnpm --filter create-bestax run build" -> "--filter create-bestax run build"
    

    It's also the wrong advice: the repo pins pnpm via packageManager, so a contributor has no
    npm/yarn/bun equivalent to be offered.

  • npx skills add … (9 blocks) — the command the skills ecosystem documents. Rewriting it
    to pnpm dlx form to fit our component would be the tail wagging the dog.

  • npm view / npm list — informational, not installs; they'd render identically on all
    four tabs.

  • Three blocks with a blank line inside the fence. splitSegments drops empty segments, so
    they can't round-trip. Left as plain fences, which preserves the visual grouping the blank
    line exists for. This is a real limitation of the component worth knowing about.

  • api/elements/pre.md (a live <Pre> demo, not an instruction) and the stock Docusaurus
    tutorial-basics/tutorial-extras pages.

  • bulma-ui (@allxsmith/bestax-bulma)

  • create-bestax (create-bestax)

  • docs (@allxsmith/bestax-docs)

Related Issue(s)

Closes #402

Type of Change

  • Documentation
  • Bug fix (the installation.md npm/pnpm error)

Verification

Every converted block is checked at build time. The component derives the authored command
back out of the fence and throws unless it renders to exactly what was written, so a bad
conversion fails the prerender rather than shipping three wrong tabs. The build passing is
the assertion that all 46 are correct.

Also checked:

  • Nested lists work — react-setups.md has 19 blocks inside numbered list items. I probed
    that shape before converting anything: all four tabs render, the <ol> survives, and the LLM
    artifact keeps the fence at its list indentation.
  • installation.md now renders all four (pnpm add / npm install / yarn add / bun add)
    and the wrong heading is gone.
  • pnpm run check:conformance — 0 violations; check:urls — all 6 resolve; docs tests 21/21;
    prettier clean.

Additional Context

The LLM artifacts keep the pnpm fence by construction — the plugin strips the wrapper and
leaves the code block — so llms.txt shows exactly what a reader sees on the default tab. No
build step involved; see docs/CLAUDE.md.

Wraps 46 command blocks across 12 guides in <PackageManagerTabs>, so readers on
npm, yarn or bun stop translating pnpm commands by hand. The component derives
the other three from the authored pnpm fence, and the shared tab group means a
choice made on one page — or in the homepage hero — is already selected on all
the others.

Fixes a live error while it is here. installation.md had three hand-written
sections: "Using npm (recommended)" sitting above a `pnpm add` command, a "Using
pnpm" section that was a byte-for-byte duplicate of it, and no bun at all. So
the page told npm readers to run pnpm. All three collapse into one component
that renders the correct command for each. No inbound links referenced the
removed anchors.

Four commands were authored outside the component's vocabulary and are rewritten
into it, which changes what pnpm users see only in that `pnpm dev` becomes the
equivalent `pnpm run dev`:

  pnpm dev                  -> pnpm run dev      (7 blocks)
  npm start                 -> pnpm run start    (2 blocks, CRA setups)
  npm install -D purgecss   -> pnpm add -D …
  npm uninstall node-sass   -> pnpm remove …

Deliberately not converted:

- `contributing.md` (9 blocks). These are monorepo commands — `pnpm exec`,
  `--filter`, `audit`, `approve-builds`, `why` — which are not package-manager
  verbs, so the component's round-trip assertion rejects them and the build
  fails. It is also the wrong advice: this repo pins pnpm via `packageManager`,
  so a contributor has no npm/yarn/bun equivalent to offer.
- `npx skills add …` (9 blocks). That is the command the skills ecosystem
  documents; rewriting it to `pnpm dlx` form to fit our component would be the
  tail wagging the dog.
- `npm view` / `npm list` — informational, not installs. They would render
  identically on all four tabs.
- Three blocks with a blank line inside the fence. `splitSegments` drops empty
  segments, so they cannot round-trip; leaving them as plain fences preserves
  the visual grouping the blank line is there for.
- `api/elements/pre.md` (a live <Pre> demo, not an instruction) and the stock
  Docusaurus tutorial pages.

Every converted block is checked at build time: the component derives the
authored command back out of the fence and throws unless it renders to exactly
what is written, so a bad conversion fails the prerender rather than shipping
three wrong tabs.

Closes #402

Claude-Session: https://claude.ai/code/session_01TGA6sFTUGsJ6oXhfpjKEnh
@coderabbitai

coderabbitai Bot commented Aug 2, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@allxsmith, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 18 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 0e693da7-614d-47bd-b5c0-19b83c3bc779

📥 Commits

Reviewing files that changed from the base of the PR and between a1fcf51 and 42a13f9.

📒 Files selected for processing (12)
  • docs/docs/guides/features/configuration.md
  • docs/docs/guides/features/sass-customization.md
  • docs/docs/guides/getting-started/alternative-icons.md
  • docs/docs/guides/getting-started/installation.md
  • docs/docs/guides/getting-started/migration/bulma-0-9-to-1.md
  • docs/docs/guides/getting-started/migration/bulma-ui-3-to-4.md
  • docs/docs/guides/getting-started/modular.md
  • docs/docs/guides/getting-started/optimizing-css.md
  • docs/docs/guides/getting-started/react-setups.md
  • docs/docs/guides/getting-started/variations.md
  • docs/docs/guides/intro.md
  • docs/docs/intro.md

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.

@github-actions

github-actions Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

Preview Deployment

Preview URL: https://86ab55d9.bestax.pages.dev

@allxsmith
allxsmith merged commit 58347fa into main Aug 2, 2026
15 checks passed
@allxsmith
allxsmith deleted the docs/pm-tabs-rollout branch August 2, 2026 00:08
@bestax-release-bot

Copy link
Copy Markdown

🎉 This PR is included in version 4.0.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@bestax-release-bot

Copy link
Copy Markdown

🎉 This PR is included in version 5.8.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@bestax-release-bot

Copy link
Copy Markdown

🎉 This PR is included in version 1.0.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@bestax-release-bot

Copy link
Copy Markdown

🎉 This PR is included in version 2.0.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Docs] Offer npm/pnpm/yarn/bun for every command — Tabs in the docs, small PM links on the homepage

1 participant