Skip to content

Fix plugin regressions - #2246

Merged
lukastaegert merged 3 commits into
masterfrom
ongenerate-fix
Jun 7, 2018
Merged

Fix plugin regressions#2246
lukastaegert merged 3 commits into
masterfrom
ongenerate-fix

Conversation

@guybedford

@guybedford guybedford commented Jun 6, 2018

Copy link
Copy Markdown
Contributor
  1. I seem to have messed up the signature of this function in the process by mistake - this returns it to its usual form as expected (resolves version 0.60.0 broke rollup-analyzer plugin #2245)
  2. I've also included a closure fix for the chunk.id handling, which must be read synchronously (resolves [0.60.0] UnhandledPromiseRejectionWarning: TypeError: Cannot set property 'code' of undefined #2243)
  3. I've fixed the multiple input validation to happen after the options hook call (resolves [0.60.0] Error: Multiple inputs are only supported for experimentalCodeSplitting #2247)

@guybedford

Copy link
Copy Markdown
Contributor Author

(also included a closure fix for the chunk.id handling, which must be read synchronously)

@guybedford guybedford changed the title Fix ongenerate signature regression Fix plugin regressions Jun 6, 2018
@guybedford

Copy link
Copy Markdown
Contributor Author

Updated to include a fix for #2247 as well

@lukastaegert lukastaegert left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Awesome quick fixes here. Will do a release shortly.

Comment thread src/rollup/index.ts
return inputOptions.plugins.reduce(applyOptionHook, inputOptions);
inputOptions = inputOptions.plugins.reduce(applyOptionHook, inputOptions);

if (!inputOptions.experimentalCodeSplitting) {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Makes a lot more sense to do these checks after plugins have been applied 👍

@lukastaegert
lukastaegert merged commit fbde57e into master Jun 7, 2018
@lukastaegert lukastaegert added this to the 0.60.1 milestone Jun 7, 2018
@lukastaegert
lukastaegert deleted the ongenerate-fix branch June 7, 2018 05:47
guybedford referenced this pull request in tivac/modular-css Jun 10, 2018
It's sort of a hack but works around rollup tree-shaking away the CSS imports (since they aren't technically being used by the JS code).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

2 participants