Skip to content

Create a "Commands" Astro component #1366

@lorenzolewis

Description

@lorenzolewis

Create a component similar to this one we had in Docusaurus but for Astro: https://github.com/tauri-apps/tauri-docs/blob/dev/src/theme/Command.js

Let's keep this simple and allow passing parameters for specifically-labeled props. Maybe an interface like this:

interface Props {
  npm?: string;
  yarn?: string;
  pnpm?: string;
  cargo?: string;
}

We would pass the full command to the component and it would conditionally render a Starlight Tabs component: https://starlight.astro.build/guides/components/#tabs

Metadata

Metadata

Assignees

Labels

good first issueIs it good for beginners to take up?help wantedCan the core maintainers not handle this themselves?

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions