Skip to main content

authoring-examples

Guidelines for writing example template files (*.examples.ts) including naming conventions, @summary JSDoc comments, and stateless HTML patterns. Use this skill whenever the user creates, modifies, or reviews *.examples.ts files, asks about example naming rules (PascalCase, 3-word max, no component prefix), needs to write or improve @summary JSDoc comments, encounters example-naming ESLint errors, or wants to add stateless or interactive examples to a component's example file.

Quellinformationen

Repository
NVIDIA/elements
Letzte Quellaktivität
12. August 2026 um 00:30
Erkannte Sprache von SKILL.md
Englisch
Sterne
102
Forks
19

Installationsoptionen

Standardmäßig ist der Prompt ausgewählt, der zuerst die Quelle prüft. Sie können zu einem direkten Befehl wechseln oder eine lokale Kopie herunterladen.

Quelldateien prüfen

Lesen Sie SKILL.md und alle von SkillsMP angezeigten Begleitdateien, bevor Sie sich für eine Installation entscheiden.

SKILL.md wird angezeigt

SKILL.md
Quellanweisungen · Schreibgeschützte Vorschau
name
authoring-examples
description
Guidelines for writing example template files (*.examples.ts) including naming conventions, @summary JSDoc comments, and stateless HTML patterns. Use this skill whenever the user creates, modifies, or reviews *.examples.ts files, asks about example naming rules (PascalCase, 3-word max, no component prefix), needs to write or improve @summary JSDoc comments, encounters example-naming ESLint errors, or wants to add stateless or interactive examples to a component's example file.
# Authoring Examples (`*.examples.ts`) You MUST review @projects/site/src/docs/internal/guidelines/examples.md before making any changes to example files. ## When to Use This Skill - Creating new `*.examples.ts` files for components - Adding or updating example templates within existing example files - Reviewing example naming conventions and structure - Writing or updating `@summary` JSDoc comments for examples ## Key Principles 1. **PascalCase Naming**: Use PascalCase for example names (for example, `Default`, `StatusFlat`, `FormSubmit`) 2. **Concise Names**: Keep example names to 1-3 words maximum, describing **what** the example shows 3. **Required @summary**: Every example must include a `@summary` JSDoc comment explaining what, why, when, and how 4. **Stateless Templates**: Examples should be stateless HTML templates demonstrating UI patterns ## Naming Patterns - Single words: `Default`, `Status`, `Size`, `Color`, `Disabled` - Compound names: `StatusFlat`, `StatusIcon`, `FormSubmit`, `VerticalTabs` - Special prefixes: `Legacy*`, `Invalid*`, `Valid*` ## References - [Examples Guidelines](/projects/site/src/docs/internal/guidelines/examples.md) - [Documentation Guidelines](/projects/site/src/docs/internal/guidelines/documentation.md)
Auf GitHub ansehen