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

feat: update build to support tree-shaking #130

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Geo25rey
Copy link

No description provided.

filename: "rarible-sdk.js",
library: {
type: "module",
},
Copy link
Contributor

Choose a reason for hiding this comment

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

wrong code: it duplicates code above

Copy link
Author

Choose a reason for hiding this comment

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

Yes. Having umd and esm builds is common practice for libraries.

Umd is compatible with everything. Esm is not, but umd doesn't support tree shaking so adding an esm build is necessary.

Check out this article for more info: link

"module": "commonjs",
"target": "es5",
"module": "ESNEXT",
"target": "es2015",
Copy link
Contributor

Choose a reason for hiding this comment

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

this is breaking changes
be careful with it

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.

3 participants