-
Notifications
You must be signed in to change notification settings - Fork 0
Closed
Labels
epicEpic - large feature areaEpic - large feature area
Description
Description
After multiple feature epics, the codebase has accumulated duplication and inconsistencies that should be addressed. This epic audits the codebase and fixes identified issues. Should be executed after the Tag/Category Rework epic, as that rework will itself eliminate some duplication and may introduce new patterns to standardize on.
Known Areas to Investigate and Fix
- CRUD route duplication: 9+ route files follow near-identical patterns (schema validation, auth checks, service delegation) — extract a shared route factory or plugin
- Modal component duplication: Multiple components implement their own modal dialogs with bespoke focus trap and keyboard handling — extract a reusable
Modalcomponent - API client wrapper inconsistency: Frontend API wrappers in
client/src/lib/have inconsistent response unwrapping patterns — standardize the convention - Error class proliferation: Multiple
*InUseErrorclasses with identical structure (e.g.,CategoryInUseError,VendorInUseError) — consider a genericResourceInUseErrorfactory - Service layer patterns: Inconsistent naming, error handling, and logging patterns across services — document and standardize
Goals
- Audit all route, service, component, and API client files for duplication and inconsistency
- Extract shared abstractions where duplication is significant (route factory, Modal component)
- Standardize API client response unwrapping convention
- Consolidate redundant error classes
- Document established patterns in project conventions (CLAUDE.md or wiki)
Execution Order
This is the second epic in a three-part sequence:
- Unified Tag & Category System (prerequisite — must complete first)
- Codebase Refinement & Consistency Cleanup ← this epic
- Construction Diary / Bautagebuch
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
epicEpic - large feature areaEpic - large feature area
Projects
Status
Wont-Do