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

Support fine grained sideEffects field in package.json #1566

Closed
devongovett opened this issue Jun 17, 2018 · 1 comment
Closed

Support fine grained sideEffects field in package.json #1566

devongovett opened this issue Jun 17, 2018 · 1 comment

Comments

@devongovett
Copy link
Member

The current implementation of tree shaking supports sideEffects: false, but some libraries need more fine grained control to allow a subset of files to include side effects. webpack allows this by supporting an array of files which contain side effects.

{
  "sideEffect": ["./foo.js", "./bar.js"]
}

For compatibility with libraries that depend on this, we should support it in Parcel as well.

@ahocevar
Copy link
Contributor

I've implemented support for the fine grained sideEffects syntax and submitted it as #1766.

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

No branches or pull requests

2 participants