Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify paths with respect to package.json exports #133

Open
justinfagnani opened this issue Aug 4, 2024 · 0 comments
Open

Clarify paths with respect to package.json exports #133

justinfagnani opened this issue Aug 4, 2024 · 0 comments

Comments

@justinfagnani
Copy link
Collaborator

Paths in manifests are meant to be fully resolvable by tools. Without package exports tools can just look up files relative to the package root. But with package exports there are two complications:

  1. Paths should be resolved via the package exports, as opposed to the filesystem.
  2. Types stop having their own paths with TypeScript's export support. Instead they have a "types" export condition on the .js path they're associated with. This means a reference to a type needs to use the .js path and either needs to include the "types" condition, or tool needs assume it.

See also #59 and #96

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

No branches or pull requests

1 participant