Skip to content
This repository has been archived by the owner on Jun 1, 2024. It is now read-only.

Published "module" in package.json should point to sources that are transpiled to ES5, except import statements #113

Closed
kayneb opened this issue Mar 5, 2018 · 1 comment

Comments

@kayneb
Copy link

kayneb commented Mar 5, 2018

As per https://github.com/rollup/rollup/wiki/pkg.module, the module field should point to JS that maintains its import/export statements, but is transpiled to ES5 otherwise. Otherwise, any consumers that are using the module field in their build tools (like rollup or webpack when tree-shaking is enabled) must also transpile this dependency.

Generally, all libraries transpile down to ES5, except the module imports so as to not burden consumers.

kayneb pushed a commit to kayneb/funfix that referenced this issue Mar 5, 2018
…ning import/export statements for tree shaking
@alexandru
Copy link
Member

Discussed in #114 — will close this for now to keep the issue tracket clean 🙂

If there are issues with the proposed solution, please open another ticket.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants