Components
This section contains documentation for reusable components and utilities used across the Tuturuuu platform.Available Components
WorkspaceWrapper
A standardized component for handling workspace ID resolution and validation across the application.- WorkspaceWrapper Guide - Complete documentation with examples
- Quick Reference - Quick reference guide
Component Guidelines
When to Create a Component
Create a new component when:- Reusability: The code is used in 2+ places
- Complexity: The logic is complex enough to warrant separation
- Testing: The component needs isolated testing
- Maintenance: The component has specific maintenance requirements
Component Structure
All components should follow this structure:Documentation Requirements
Each component must include:- Purpose: What the component does
- Props: Complete API reference
- Examples: Real-world usage examples
- Migration Guide: If replacing existing patterns
- Best Practices: Usage guidelines
Naming Conventions
- Components: PascalCase (
WorkspaceWrapper
) - Files: kebab-case (
workspace-wrapper.mdx
) - Props: camelCase (
searchParams
) - Types: PascalCase with descriptive suffixes (
WorkspaceWrapperProps
)
Contributing
When adding new components:- Create the component in the appropriate app’s
components/
directory - Add comprehensive documentation
- Include TypeScript types
- Add tests
- Update this index page
- Follow the established patterns