[loggi-ua9] Consider splitting stats-charts.js into multiple files #115

Closed
opened 2026-02-21 19:08:15 +01:00 by matthias · 0 comments
Owner

Bead ID: loggi-ua9
Type: task
Priority: P3
Status: closed
Close reason: Split stats-charts.js (913 lines) into 3 files: stats-charts-cards.js (263 lines, summary + heatmap), stats-charts-trends.js (382 lines, time-series charts), stats-charts-dist.js (288 lines, distribution charts). Updated entry.html script loading and architecture.md. All tests pass.


stats-charts.js has grown to 913 lines after adding 4 new chart renderers (cumulative, gap analysis, duration distribution, word count distribution). While each renderer is concise, the file now significantly exceeds the ~300 line guideline for JS files. Consider splitting into stats-charts-core.js (existing charts) and stats-charts-extra.js (new histogram/distribution charts), or by chart category.

**Bead ID:** `loggi-ua9` **Type:** task **Priority:** P3 **Status:** closed **Close reason:** Split stats-charts.js (913 lines) into 3 files: stats-charts-cards.js (263 lines, summary + heatmap), stats-charts-trends.js (382 lines, time-series charts), stats-charts-dist.js (288 lines, distribution charts). Updated entry.html script loading and architecture.md. All tests pass. --- stats-charts.js has grown to 913 lines after adding 4 new chart renderers (cumulative, gap analysis, duration distribution, word count distribution). While each renderer is concise, the file now significantly exceeds the ~300 line guideline for JS files. Consider splitting into stats-charts-core.js (existing charts) and stats-charts-extra.js (new histogram/distribution charts), or by chart category.
Sign in to join this conversation.
No labels
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
matthias/loggi#115
No description provided.