Skip to content

Standardize on Named Exports Throughout Codebase #33

@prasadhonrao

Description

@prasadhonrao

Description

Convert all default exports to named exports for consistency and better tree-shaking.

Current State

Mixed use of default and named exports:

  • export default config in config.js
  • export default logger in logger.js
  • Named exports in controllers

Proposed Solution

Use named exports consistently:

// Before
export default config;

// After
export { config };
export default config; // Keep for backward compatibility initially

Benefits

  • Better tree-shaking in bundlers
  • Clearer import statements
  • Prevents naming conflicts
  • Easier refactoring

Priority

Medium - Code consistency improvement

Related Files

  • src/core/config.js
  • src/core/logger.js
  • All middleware files

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions