How marc2332/freya works
Main Components Identification
The system should be divided into these major components:
a. Core Architecture:
• Native Core (crates/native-core): Handles the fundamental rendering system
• Core (crates/core): Manages DOM, events, and rendering pipeline
• Engine (crates/engine): Provides rendering backends (Skia)
• State (crates/state): Manages application state and styling
• Torin (crates/torin): Layout engine
b. User-Facing Layers:
• Components (crates/components): Pre-built UI components
• Elements (crates/elements): Basic building blocks
• Hooks (crates/hooks): Reusable logic components
• Freya (crates/freya): Main public API
c. Development Tools:
• DevTools (crates/devtools): Developer tooling
• Testing (crates/testing): Testing infrastructure
[User Application Layer]
• ↓
[Freya Public API]
• ↓
┌─────────────────────────────────┐
• Component Layer │
• ┤
• Pre-built Components │
• Custom Elements │
• Hooks │
• ┘
• ↓
┌─────────────────────────────────┐
• Core Layer │
• ┤
• DOM Management │
• Event System │
• Rendering Pipeline │
• State Management │
• ┘
• ↓
┌─────────────────────────────────┐
• Platform Layer │
• ┤
• Skia Rendering │
• Native Windowing │
• Platform Integration │
• ┘
Key Relationships to Highlight
• Event propagation paths
• State management connections
• Integration points with Dioxus and Skia
Important Details
• Event system architecture
• Rendering pipeline flow
• State management system
• Component hierarchy
• Testing infrastructure
• DevTools integration
Architectural Patterns to Emphasize
• Component-based architecture
• Event-driven system
• Layered architecture
• Platform abstraction
Integration Points
• How Dioxus integration works
• Skia rendering pipeline
• Platform-specific adaptations
• Testing and DevTools hooks
Remember to highlight Freya's unique features:
• Native (non-web) implementation
• Cross-platform support
• Built-in component system
• Developer tools integration
• Testing infrastructure
• Theming support
• Accessibility features
This will help developers understand both the high-level architecture and the detailed implementation specifics of the Freya UI library.