Skip to content

refactor: remove redundant re-exports in src/tui #746

Description

@avoidwork

Restructure Analysis: ./src/tui

Summary

The ./src/tui directory is well-organized with 19 files at a single level. The primary finding is redundant re-exports that add no value.

Findings

File/Directory Issue Type Impact Summary Recommendation
./src/tui/hooks.js cohesion low nextPanel and prevPanel just re-export from panels.js with no added logic Remove these re-exports, update consumers to import from panels.js directly
./src/tui/components.js cohesion low Barrel file re-exports 7 components that are also re-exported via index.js Merge into index.js or remove if unused

Proposed Structure

No structural changes required. Just clean up:

// Remove from hooks.js:
// export function nextPanel(current) { return _nextPanel(current); }
// export function prevPanel(current) { return _prevPanel(current); }

// Update consumers to import from panels.js directly

Restructuring Priority

  1. Remove redundant nextPanel/prevPanel from hooks.js
  2. Check if components.js is imported anywhere; if not, remove it
  3. Update any consumers of components.js to use index.js instead

Metadata

Metadata

Assignees

No one assigned

    Labels

    approvedAn identifier for Madz to take action.bugSomething isn't workingin progress

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions