Skip to content
This repository has been archived by the owner on Apr 16, 2020. It is now read-only.

WIP: Specify file resolution and exports #22

Closed
wants to merge 17 commits into from

Conversation

guybedford
Copy link
Contributor

This PR combines the spec for the file resolution proposal in #19, with the exports spec from https://github.com/jkrems/proposal-pkg-exports/.

I've put together an experimental implementation of this spec at https://github.com/guybedford/node/tree/irp-implementation if anyone wants to try it out.

Feedback welcome.

doc/api/esm.md Show resolved Hide resolved
@guybedford guybedford dismissed devsnek’s stale review December 19, 2018 15:11

implementation already does this, spec corrected.

@guybedford guybedford force-pushed the irp-exports branch 3 times, most recently from 5a38f6c to 86557e7 Compare December 19, 2018 15:48
> 1. Return _pjson_.

HAS_ESM_PROPERTIES(_pjson_)
> 1. If _pjson_ is not **null** and _pjson.exports_ is a String or Object, then

Choose a reason for hiding this comment

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

I'm going to continue to insist that exports is useful for non-esm packages and shouldn't be an esm marker.

Copy link
Member

@devsnek devsnek Dec 19, 2018

Choose a reason for hiding this comment

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

It's also worth noting that this has an impact on how node deals with package.json from a performance standpoint.

@MylesBorins
Copy link
Contributor

@guybedford gone ahead and rebase this against the new modules-lkgr

guybedford and others added 8 commits January 15, 2019 09:06
Refs: nodejs/modules#180

PR-URL: nodejs#6
Reviewed-By: Myles Borins <MylesBorins@google.com>
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Refs: nodejs/modules#180

PR-URL: nodejs#6
Reviewed-By: Guy Bedford <guybedford@gmail.com>
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Refs: nodejs/modules#180

PR-URL: nodejs#6
Reviewed-By: Guy Bedford <guybedford@gmail.com>
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Refs: nodejs/modules#180

PR-URL: nodejs#6
Reviewed-By: Guy Bedford <guybedford@gmail.com>
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
PR-URL: nodejs#6
Reviewed-By: Guy Bedford <guybedford@gmail.com>
Reviewed-By: John-David Dalton <john.david.dalton@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
PR-URL: nodejs#6
Reviewed-By: Guy Bedford <guybedford@gmail.com>
Reviewed-By: Myles Borins <mylesborins@google.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
PR-URL: nodejs#6
Reviewed-By: Guy Bedford <guybedford@gmail.com>
Reviewed-By: Myles Borins <mylesborins@google.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
@guybedford
Copy link
Contributor Author

Replaced by #28.

@guybedford guybedford closed this Jan 27, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants