Skip to content

Conversation

@lenard123
Copy link

✔️ Motivation / Why This Is Needed

  • This is a purely type-level improvement with no runtime implications.
  • It allows consumers of the library to strongly type the close data, improving DX and reducing the need for downstream type assertions.
  • Backward compatibility is fully preserved because T defaults to any.

🔍 Scope / Impact

  • No breaking changes
  • No functional changes
  • No behavioral changes
  • Only TypeScript generics applied to improve type accuracy
  • This aligns with common TypeScript patterns and adds flexibility while keeping defaults unchanged

🐛 Defect Fixes (if applicable)

Although minor, this change addresses the loosely-typed nature of data?: any, which may lead to incorrect assumptions in consuming code.
To comply with project policy, an issue has been created documenting the type safety problem.

🏢 Company Policy Alignment

This PR does not introduce a feature request or significant behavioral change.
It is a small, backward-compatible typing improvement that enhances developer experience while staying within the project's guidelines.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant