Skip to content

[Refactor] Componentize Large React Files and Implement Error Boundaries #407

@basantnema31

Description

@basantnema31

Description

Several page components within the src/ directory have grown quite large and complex, containing multiple concerns (data fetching, state management, and UI rendering) within a single file. Furthermore, if a child component throws an error during rendering, it currently crashes the entire React tree.

Proposed Solution

  1. Extract UI Components: Break down large monolithic page components into smaller, reusable presentational components.
  2. Implement Error Boundaries: Create a global <ErrorBoundary> component and wrap critical sections of the app (like dashboard panels or data feeds).
  3. Fallback UI: Design a user-friendly fallback UI that displays when an error is caught, preventing a total white-screen crash.

Why this matters

Improves code maintainability and vastly improves the resilience of the application in production.

Suggested labels: gssoc, quality:clean, level:intermediate, type:refactor, area:frontend

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions