refactor: centralize dashboard server data loaders #319

Closed
opened 2026-05-11 19:19:51 +00:00 by barrettruth · 0 comments
Owner

Parent: #305

Problem

Dashboard route components fetch task, category, color, settings, and view data directly. As Google sync and self-hosting behavior land, route-level fetching will get harder to reason about unless the server data boundary is explicit.

Solution

Add a server-only dashboard data module:

  • shell data: current owner, sidebar categories, category colors
  • queue data: filtered tasks and show-done handling
  • kanban data: board task set
  • calendar data: calendar events/tasks and relevant settings
  • keep pure domain operations in src/core/*; the loader should coordinate route needs, not become the task domain

Acceptance criteria

  • Dashboard pages call named loader functions instead of hand-assembling repeated DB queries.
  • Loader functions have clear input/output types.
  • No client component imports server-only DB code.
  • next build still treats authenticated dashboard routes as dynamic.
  • Existing page behavior is unchanged.
Parent: #305 ## Problem Dashboard route components fetch task, category, color, settings, and view data directly. As Google sync and self-hosting behavior land, route-level fetching will get harder to reason about unless the server data boundary is explicit. ## Solution Add a server-only dashboard data module: - shell data: current owner, sidebar categories, category colors - queue data: filtered tasks and show-done handling - kanban data: board task set - calendar data: calendar events/tasks and relevant settings - keep pure domain operations in `src/core/*`; the loader should coordinate route needs, not become the task domain ## Acceptance criteria - Dashboard pages call named loader functions instead of hand-assembling repeated DB queries. - Loader functions have clear input/output types. - No client component imports server-only DB code. - `next build` still treats authenticated dashboard routes as dynamic. - Existing page behavior is unchanged.
barrettruth added this to the v0.1.0 milestone 2026-05-11 19:19:51 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
barrettruth/delta#319
No description provided.