fix(package): Add exports field in package.json#1347
fix(package): Add exports field in package.json#1347dnalborczyk wants to merge 1 commit intonode-fetch:mainfrom
Conversation
|
I really wish that we would have done this before 3.0.0 😅 I'm not sure we can do this now since this technically breaks things that worked before, e.g. On the other hand one could argue that it was never supported nor documented. Will have to see what the other maintainers thinks... |
I agree, "technically" it's a breaking change, but that would also technically prevent you from ever doing any refactoring as well without a major version release, as someone could also depend on e.g. formDataIterator which is not meant to be exposed at all. I also think that an import like
I agree. as far as I noticed, people usually treated their non-documented code not as semver major changes. if anyone feels really strongly about it tho: "integers are cheap" 😉 I personally don't think it's a big deal to release 4.0, even shortly after a 3.0. |
What is the purpose of this pull request?
adds an
exportsfield topackage.jsonwhich limits the accessibility toindex.jsonly.What changes did you make? (provide an overview)
Which issue (if any) does this pull request address?
Is there anything you'd like reviewers to know?