feat(stats): optimize dashboard data loading with internal ui endpoints
This commit is contained in:
29
CHANGELOG.md
Normal file
29
CHANGELOG.md
Normal file
@@ -0,0 +1,29 @@
|
||||
# Changelog
|
||||
|
||||
## Unreleased
|
||||
|
||||
### Changed
|
||||
|
||||
- Optimized the HTML dashboard data flow by splitting board loading and task detail loading.
|
||||
- Kept the public `/api/tasks/*` API unchanged.
|
||||
- Added internal `/ui_data/*` routes for lightweight board data and on-demand task details.
|
||||
- Updated the `/stats` page to load a lightweight board model first and fetch full task details only for the selected task.
|
||||
- Hid internal UI routes from Swagger / OpenAPI documentation.
|
||||
- Updated tests and project documentation to match the new dashboard behavior.
|
||||
|
||||
### Why
|
||||
|
||||
- The previous dashboard rendered the full task payload for every card directly into the HTML.
|
||||
- This caused unnecessary data transfer and made the page size grow linearly with the number of tasks.
|
||||
- The change reduces the initial payload and loads detailed data only when it is actually needed.
|
||||
|
||||
### Effect
|
||||
|
||||
- The `/stats` HTML response became nearly constant in size instead of growing with the full board.
|
||||
- Embedded per-card task payloads were removed from the DOM.
|
||||
- The dashboard now transfers less data on initial load and keeps full task details as a separate targeted request.
|
||||
- Measured impact on a 1000-task dataset:
|
||||
- `/stats` HTML reduced from `632,377 B` to `11,413 B`
|
||||
- embedded task payload reduced from `250,800 B` to `0 B`
|
||||
- full board data moved into a lightweight JSON response (`162,656 B`)
|
||||
- selected task details are loaded separately in a small response (`179 B`)
|
||||
Reference in New Issue
Block a user