Skip to content

fix: 🐛 correct env-utils exports paths to match actual dist extensions - #214

Merged
iamnewton merged 1 commit into
mainfrom
fix/env-utils-exports
Aug 7, 2026
Merged

fix: 🐛 correct env-utils exports paths to match actual dist extensions#214
iamnewton merged 1 commit into
mainfrom
fix/env-utils-exports

Conversation

@iamnewton

Copy link
Copy Markdown
Contributor

Summary

The library preset outputs index.mjs and index.d.mts but the exports field in package.json referenced index.js and index.d.ts — files that don't exist. This caused TypeScript to fail resolving the package when moduleResolution: "bundler" is used (which strictly follows the exports map without fallback).

Fix

Update the exports to match the actual build output:

{
  ".": {
    "import": "./dist/index.mjs",
    "types": "./dist/index.d.mts"
  }
}

Test plan

  • pnpm --filter @theholocron/env-utils build — clean build
  • pnpm --filter @theholocron/env-utils test — 138/138 pass
  • CI passes

The library preset outputs index.mjs and index.d.mts but exports
referenced index.js and index.d.ts which don't exist. TypeScript with
moduleResolution: "bundler" strictly follows the exports map and fails
when the referenced files are missing.

Signed-off-by: Newton <vj2kp2hfh4@privaterelay.appleid.com>
Signed-off-by: Newton <5769156+iamnewton@users.noreply.github.com>
@iamnewton
iamnewton requested a review from a team as a code owner August 7, 2026 05:35
@codecov

codecov Bot commented Aug 7, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ All tests successful. No failed tests found.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #214   +/-   ##
=======================================
  Coverage   97.43%   97.43%           
=======================================
  Files          22       22           
  Lines         234      234           
  Branches       57       57           
=======================================
  Hits          228      228           
  Partials        6        6           
🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@iamnewton
iamnewton merged commit bcc46f6 into main Aug 7, 2026
30 checks passed
@iamnewton
iamnewton deleted the fix/env-utils-exports branch August 7, 2026 05:38
@iamnewton

Copy link
Copy Markdown
Contributor Author

🎉 This PR is included in version 1.2.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@iamnewton iamnewton added the released Included in a release label Aug 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

released Included in a release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant