feat: mark files in a node_modules as ignore-listed by default#4877
Conversation
✅ Deploy Preview for rollupjs ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
Codecov Report
@@ Coverage Diff @@
## master #4877 +/- ##
=======================================
Coverage 98.98% 98.98%
=======================================
Files 219 219
Lines 7948 7951 +3
Branches 2189 2190 +1
=======================================
+ Hits 7867 7870 +3
Misses 26 26
Partials 55 55
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
d5509d6 to
ed11971
Compare
There was a problem hiding this comment.
Thank you!
While I approve the change in general, now the only way to switch it off is to pass a function that always returns false.
I think we should adjust the types and handling slightly:
- E.g. allow an explicit
falseto turn off the feature. That would be consistent with how this works for other options liketreeshakeorwatch - Either translate
falseto an "always false" predicate and have always a function in thenormalizedOutputOptions, or hand through thefalsevalue. I am slightly leaning to the former approach of always having a function for simplicity. In that case, we can remove the conditional logic inrenderChunksthat is currently not covered.
And of course, documentation should be adapted to show the new types and explain the default logic.
ed11971 to
931b43b
Compare
Done, thanks! |
Following up on the addition of the `sourcemapIgnoreList` output option, this adds a default which marks all files within a `node_modules` folder as ignore-listed. This way most projects using rollup will need no additional configuration regarding the ignore-listing and automatically benefit. This also allows to specify `false` for the `sourcemapIgnoreList` output option, which completely disables the generation of an ignore-list. Doc: https://goo.gle/devtools-ignoreList-adoption
931b43b to
ca3eba9
Compare
|
This PR has been released as part of [email protected]. You can test it via |
This PR contains:
Are tests included?
Breaking Changes?
List any relevant issue numbers:
#4847
Description
Following up on the addition of the
sourcemapIgnoreListoutput option, this adds a default which marks all files within anode_modulesfolder as ignore-listed. This way most projects using rollup will need no additional configuration regarding the ignore-listing and automatically benefit.Doc: https://goo.gle/devtools-ignoreList-adoption