fix(build): override rollup-plugin-typescript2 for picomatch compatibility - #361
Open
hasanefeuygun wants to merge 1 commit into
Open
fix(build): override rollup-plugin-typescript2 for picomatch compatibility#361hasanefeuygun wants to merge 1 commit into
hasanefeuygun wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Override Microbundle's
rollup-plugin-typescript2dependency to version0.37.0.This restores the build on the current
mainbranch after the upgrade topicomatch@2.3.2.Root cause
microbundle@0.15.1uses an older version ofrollup-plugin-typescript2.That version uses the following default include patterns for TypeScript files:
After the upgrade to
picomatch@2.3.2, these patterns no longer match plain.tsfiles.As a result:
rollup-plugin-typescript2skips plain.tssource files.export type.rollup-plugin-typescript2@0.37.0uses the compatible patterns:Changes
Added a scoped npm override so that only Microbundle's
rollup-plugin-typescript2dependency is replaced:The Microbundle version itself remains unchanged.
Bisect result
git bisectidentified the first bad commit as:The parent commit builds successfully in the same environment.
Verification
Verified from a clean installation:
Additional checks:
npm run checknpm test— 48 test suites and 453 tests passedgit diff --checkThe build successfully generated the expected CJS, ESM, and UMD bundles.
Fixes #360
Summary by cubic
Restore the build after upgrading to
picomatch@2.3.2by overridingmicrobundle’srollup-plugin-typescript2to0.37.0, ensuring.tsfiles are correctly matched and transpiled.microbundle@0.15.1depended onrollup-plugin-typescript2@0.32.xwhich used*.ts+(|x)patterns that no longer match inpicomatch@2.3.2, so.tsfiles were skipped and Babel failed.overridesblock to pin onlymicrobundle’srollup-plugin-typescript2to0.37.0(uses*.ts{,x});microbundleitself is unchanged.Written for commit 9ff1337. Summary will update on new commits.