Skip to content

Improve ioredis exports to optimize bundle size #3079

@Romakita

Description

@Romakita

Context

To reduce bundle size and improve modularity, the IORedisStore should no longer be exported from the main index.ts of @tsed/ioredis. Instead, it should be exposed via a dedicated export path: @tsed/ioredis/cache.

Objective

Update the exports field of the @tsed/ioredis module so that:

  • Consumers must import IORedisStore from @tsed/ioredis/cache instead of the package root.

Deliverables

Subtask 1: Prepare for Transition in Ts.ED v8

  • Expose IORedisStore through the new export path: @tsed/ioredis/cache (TypeScript & JS).
  • Deprecate the export from the main index.ts but keep it available for backward compatibility.
  • Add deprecation warnings and update documentation to inform users about the new import path.

Subtask 2: Breaking Change in Ts.ED v9

  • Remove IORedisStore export from the package root (index.ts).
  • Ensure IORedisStore is only accessible via @tsed/ioredis/cache.
  • Update documentation and migration guides to reflect the breaking change.

Acceptance Criteria

  • IORedisStore is accessible via @tsed/ioredis/cache in v8 (with deprecation notice).
  • IORedisStore is no longer accessible via the package root in v9.

Sub-issues

Metadata

Metadata

Assignees

Projects

Status

Review approved

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions