Rspress Components

by savvy-web

codedocument

Use RSPress built-in components and MDX features in documentation. Use when adding interactive elements like tabs, badges, steps, callouts, or code groups to documentation pages.

Skill Details

Repository Files

1 file in this skill directory


name: rspress-components description: Use RSPress built-in components and MDX features in documentation. Use when adding interactive elements like tabs, badges, steps, callouts, or code groups to documentation pages. allowed-tools: Read, Write, Edit, Glob

RSPress Components Skill

Guide for using RSPress built-in components and MDX features in documentation.

Importing Components

Import built-in components from rspress/theme:

import { Badge, Tabs, Tab } from 'rspress/theme';

Common Components

Badge

Display inline status badges:

<Badge type="info" text="Info" />
<Badge type="tip" text="Tip" />
<Badge type="warning" text="Warning" />
<Badge type="danger" text="Danger" />

Tabs

Create tabbed content sections:

import { Tabs, Tab } from 'rspress/theme';

<Tabs>
  <Tab label="JavaScript">
    ```javascript
    console.log('Hello');
    ```
  </Tab>
  <Tab label="TypeScript">
    ```typescript
    console.log('Hello');
    ```
  </Tab>
</Tabs>

PackageManagerTabs

Special tabs for package manager commands:

import { PackageManagerTabs } from 'rspress/theme';

<PackageManagerTabs command="install react" />
<PackageManagerTabs command="add -D typescript" />

Steps

Create numbered step-by-step instructions:

import { Steps } from 'rspress/theme';

<Steps>
### Step 1

First instruction.

### Step 2

Second instruction.
</Steps>

NoSSR

Prevent server-side rendering for client-only components:

import { NoSSR } from 'rspress/theme';

<NoSSR>
  <ClientOnlyComponent />
</NoSSR>

Code Block Features

Syntax Highlighting

Specify language for automatic syntax highlighting:

```typescript
const example: string = "code";
```

Line Highlighting

Highlight specific lines with {line-numbers}:

```typescript{2,4-6}
const a = 1;
const b = 2; // highlighted
const c = 3;
const d = 4; // highlighted
const e = 5; // highlighted
const f = 6; // highlighted
```

Diff Highlighting

Show additions and deletions with // [!code ++] and // [!code --]:

```typescript
const old = 'remove'; // [!code --]
const new = 'add'; // [!code ++]
```

Container Blocks

Callouts

Create styled callout boxes:

:::tip
Helpful tip content
:::

:::info
Informational content
:::

:::warning
Warning content
:::

:::danger
Danger/error content
:::

Details (Collapsible)

Create collapsible sections:

:::details Summary text
Hidden content that can be expanded
:::

MDX Features

Importing Custom Components

import CustomComponent from '../components/CustomComponent';

<CustomComponent prop="value" />

Inline Expressions

Use JavaScript expressions inline:

export const version = '1.0.0';

Current version: {version}

Mixing Markdown and JSX

<div className="custom-wrapper">

## Markdown heading

Regular markdown content works inside JSX.

</div>

Best Practices

  • Use PackageManagerTabs for install commands to support all package managers
  • Add language identifiers to all code blocks for proper syntax highlighting
  • Use appropriate callout types (tip/info/warning/danger) for context
  • Import only the components you need to minimize bundle size
  • Use NoSSR sparingly, only when necessary for client-only features

Related Skills

Dbt Transformation Patterns

Master dbt (data build tool) for analytics engineering with model organization, testing, documentation, and incremental strategies. Use when building data transformations, creating data models, or implementing analytics engineering best practices.

testingdocumenttool

Clinical Decision Support

Generate professional clinical decision support (CDS) documents for pharmaceutical and clinical research settings, including patient cohort analyses (biomarker-stratified with outcomes) and treatment recommendation reports (evidence-based guidelines with decision algorithms). Supports GRADE evidence grading, statistical analysis (hazard ratios, survival curves, waterfall plots), biomarker integration, and regulatory compliance. Outputs publication-ready LaTeX/PDF format optimized for drug develo

developmentdocumentcli

Scientific Schematics

Create publication-quality scientific diagrams using Nano Banana Pro AI with smart iterative refinement. Uses Gemini 3 Pro for quality review. Only regenerates if quality is below threshold for your document type. Specialized in neural network architectures, system diagrams, flowcharts, biological pathways, and complex scientific visualizations.

artdocument

Mermaid Diagrams

Comprehensive guide for creating software diagrams using Mermaid syntax. Use when users need to create, visualize, or document software through diagrams including class diagrams (domain modeling, object-oriented design), sequence diagrams (application flows, API interactions, code execution), flowcharts (processes, algorithms, user journeys), entity relationship diagrams (database schemas), C4 architecture diagrams (system context, containers, components), state diagrams, git graphs, pie charts,

artdesigncode

Diagram Generation

Mermaid diagram generation for architecture visualization, data flow diagrams, and component relationships. Use for documentation, PR descriptions, and architectural analysis.

documentdata

Matlab

MATLAB and GNU Octave numerical computing for matrix operations, data analysis, visualization, and scientific computing. Use when writing MATLAB/Octave scripts for linear algebra, signal processing, image processing, differential equations, optimization, statistics, or creating scientific visualizations. Also use when the user needs help with MATLAB syntax, functions, or wants to convert between MATLAB and Python code. Scripts can be executed with MATLAB or the open-source GNU Octave interpreter

codedata

Dask

Distributed computing for larger-than-RAM pandas/NumPy workflows. Use when you need to scale existing pandas/NumPy code beyond memory or across clusters. Best for parallel file processing, distributed ML, integration with existing pandas code. For out-of-core analytics on single machine use vaex; for in-memory speed use polars.

codeworkflow

Scientific Schematics

Create publication-quality scientific diagrams using Nano Banana Pro AI with smart iterative refinement. Uses Gemini 3 Pro for quality review. Only regenerates if quality is below threshold for your document type. Specialized in neural network architectures, system diagrams, flowcharts, biological pathways, and complex scientific visualizations.

artdocument

Clinical Decision Support

Generate professional clinical decision support (CDS) documents for pharmaceutical and clinical research settings, including patient cohort analyses (biomarker-stratified with outcomes) and treatment recommendation reports (evidence-based guidelines with decision algorithms). Supports GRADE evidence grading, statistical analysis (hazard ratios, survival curves, waterfall plots), biomarker integration, and regulatory compliance. Outputs publication-ready LaTeX/PDF format optimized for drug develo

developmentdocumentcli

Materialize Docs

Materialize documentation for SQL syntax, data ingestion, concepts, and best practices. Use when users ask about Materialize queries, sources, sinks, views, or clusters.

documentdata

Skill Information

Category:Technical
Allowed Tools:Read, Write, Edit, Glob
Last Updated:12/7/2025