Skip to content

fix(exports): add ./lib/module subpath export for Vite 8#1826

Open
bmiit145 wants to merge 1 commit intosamchon:masterfrom
bmiit145:fix/1805-export-lib-module-vite8
Open

fix(exports): add ./lib/module subpath export for Vite 8#1826
bmiit145 wants to merge 1 commit intosamchon:masterfrom
bmiit145:fix/1805-export-lib-module-vite8

Conversation

@bmiit145
Copy link
Copy Markdown

Summary

Add the missing ./lib/module subpath in publishConfig.exports for the typia package.

Problem

Vite 8 dev resolution fails with:
"./lib/module is not exported" from typia.

Changes

  • Updated packages/typia/package.json
  • Added:
    • ./lib/module.types -> ./lib/index.d.ts
    • ./lib/module.import -> ./lib/index.mjs
    • ./lib/module.default -> ./lib/index.js

Why this fix

This restores compatibility with tooling (including Vite 8) that resolves the typia/lib/module subpath under ESM conditions.

Closes #1805

Copilot AI review requested due to automatic review settings April 27, 2026 08:21
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes Vite 8 dev-time module resolution for the published typia package by adding the missing ./lib/module subpath to the package’s published exports map (via publishConfig.exports).

Changes:

  • Add ./lib/module to publishConfig.exports, pointing to the existing built entrypoints (index.d.ts, index.mjs, index.js).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown
Owner

@samchon samchon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this bug happens from vite?

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.

Typia 12 incompatible with Vite 8.

3 participants