Building: notification to remind you to do it Breaking: review at the end of the day to check if did it
This React Native application follows a feature-based architecture using Expo and Expo Router. The architecture is designed to be scalable, maintainable, and follows React Native best practices.
├── app/ # Application routing and screens
│ ├── (tabs)/ # Tab-based navigation
│ ├── _layout.tsx # Root layout configuration
│ └── +not-found.tsx # 404 error handling
│
├── components/ # Reusable UI components
│ ├── ui/ # Basic UI elements
│ ├── __tests__/ # Component tests
│ └── [Component].tsx # Individual components
│
├── constants/ # Application-wide constants
│ └── Colors.ts # Theme and color definitions
│
├── hooks/ # Custom React hooks
│ ├── useColorScheme # Theme management
│ └── useThemeColor # Color utilities
│
└── assets/ # Static assets (images, fonts, etc.)
-
Routing & Navigation
- Uses Expo Router for file-based routing
- Tab-based navigation structure in
app/(tabs)
- Centralized layout management in
_layout.tsx
-
Component Architecture
- Separation of UI components into reusable pieces
- Component-specific tests in
__tests__
directory - Themed components for consistent styling
-
State Management
- React's built-in state management
- Custom hooks for shared logic
- Theme management through dedicated hooks
-
Styling & Theming
- Centralized color management in
constants/Colors.ts
- Theme-aware components using
useThemeColor
- Support for light/dark mode through
useColorScheme
- Centralized color management in
-
Base Components
ThemedText.tsx
- Text with theme supportThemedView.tsx
- Container with theme supportExternalLink.tsx
- External URL handling
-
Interactive Components
Collapsible.tsx
- Expandable/collapsible contentHapticTab.tsx
- Haptic feedback enabled tabParallaxScrollView.tsx
- Scrolling with parallax effect
-
New Features
- Add new screens in the
app
directory - Create reusable components in
components
- Implement business logic in custom hooks
- Add new screens in the
-
Styling
- Use the theme system via
useThemeColor
- Define new colors in
Colors.ts
- Maintain consistent component styling
- Use the theme system via
-
Testing
- Place component tests in
__tests__
directory - Follow existing test patterns
- Place component tests in