Demo
After installing the package, you can use the component provided by starlight-package-managers
in any MDX files of your Starlight documentation site.
---
title: My Docs
---
import { PackageManagers } from 'starlight-package-managers'
<PackageManagers pkg="astro" />
The code above generates the following commands:
npm i astro
yarn add astro
pnpm add astro
Package manager tabs are also synced between each instance on the same page.
npm create astro@latest -- --template starlight
yarn create astro@latest --template starlight
pnpm create astro@latest --template starlight