Skip to content

Add types condition to exports field in package.json#22

Merged
j9t merged 1 commit intomainfrom
fix/typescript-types-export
Feb 16, 2026
Merged

Add types condition to exports field in package.json#22
j9t merged 1 commit intomainfrom
fix/typescript-types-export

Conversation

@j9t
Copy link
Owner

@j9t j9t commented Feb 16, 2026

Resolves #21

Summary by CodeRabbit

  • Bug Fixes
    • Fixed TypeScript type declaration discovery for TypeScript projects using modern module resolution settings.

Added a `types` condition to the `exports` field to ensure TypeScript can locate type declarations with modern `moduleResolution` settings. Bumped the package version to 1.1.2 and updated the CHANGELOG with details of this fix.

(This commit message was AI-generated.)

Signed-off-by: Jens Oliver Meiert <jens@meiert.com>
@coderabbitai
Copy link

coderabbitai bot commented Feb 16, 2026

No actionable comments were generated in the recent review. 🎉


Walkthrough

This change addresses a TypeScript type discovery issue by adding a types export declaration to package.json and bumping the version to 1.1.2. The types field explicitly points TypeScript to the type declarations file for compatibility with modern moduleResolution settings.

Changes

Cohort / File(s) Summary
Configuration & Version
package.json, CHANGELOG.md
Version bumped to 1.1.2. Added types export field pointing to ./types/index.d.ts under the main export to enable TypeScript type discovery with modern moduleResolution settings.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~4 minutes

🚥 Pre-merge checks | ✅ 6
✅ Passed checks (6 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title directly describes the main change: adding a types condition to the exports field in package.json, which is the core fix for the TypeScript type discovery issue.
Linked Issues check ✅ Passed The PR successfully addresses issue #21 by adding the types condition to the exports field, enabling TypeScript to discover type declarations with modern moduleResolution settings.
Out of Scope Changes check ✅ Passed All changes are directly related to fixing the TypeScript type discovery issue: package.json exports field update, version bump, and CHANGELOG entry. No unrelated changes detected.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Merge Conflict Detection ✅ Passed ✅ No merge conflicts detected when merging into main

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix/typescript-types-export

Tip

Issue Planner is now in beta. Read the docs and try it out! Share your feedback on Discord.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@j9t j9t merged commit 01fb513 into main Feb 16, 2026
8 checks passed
@j9t j9t deleted the fix/typescript-types-export branch February 16, 2026 18:43
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.

Types not available

1 participant