xyd 0.1.0-beta - Coming Soon

API Pages
/
UI Components

UI ComponentsExperimental

Reference UI Components in your docs pages

Currently, only React components are supported.

API Docs Generation Explanation

  • The generator automatically creates API documentation based on your UI components

  • Extracts prop types and their descriptions from TypeScript definitions

  • Groups props by their categories (required, optional, etc.)

  • Shows default values and prop types

  • Displays component usage examples

Setup Component Configuration

  1. To create an API documentation page for a component, specify its path in the meta using uniform:

  2. Mark component function in code:

  3. alternatively using@component:

Example

Here's a full example of a React component and how it will be documented:

This will generate an API documentation page that shows:

  • Component name and description
  • Props info with:
    • Prop name
    • Type
    • Required status
    • Description from TypeDoc comments
  • Usage examples
  • TypeScript interface definitions

Please make sure you mentioned @category Component or @component in TypeDoc comment.

CompositionComing Soon

You can use composition to make your component API page more custom:

Built with

Show your support! Star us on GitHub ⭐️