deps: upgrade rpt2 to latest v0.32.0 to fix monorepos#967
Merged
rschristian merged 2 commits intodevelopit:masterfrom Jun 2, 2022
Merged
deps: upgrade rpt2 to latest v0.32.0 to fix monorepos#967rschristian merged 2 commits intodevelopit:masterfrom
rschristian merged 2 commits intodevelopit:masterfrom
Conversation
- rpt2 v0.30.0 supports compiling files outside of the project directory
with no additional configuration (e.g. of `rootDir`) as it upgraded
its dep of `@rollup/pluginutils` to v4, which has a breaking change
affecting `createFilter`
- essentially, the change to `@rollup/pluginutils` allows transforming
files outside of the project dir
- rpt2 v0.32.0 supports symlinks, such as with monorepos built w/ pnpm
- previously, microbundle was using rpt2 v0.29.0, which is about ~1.5
years out-of-date
🦋 Changeset detectedLatest commit: 336a485 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Merged
2 tasks
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.
Intro
Hi 👋 , by way of introduction, I help maintain
rollup-plugin-typescript2and also formerly solo-maintained TSDX for ~1.5 years (the creator hasn't been involved in years and his abusiveness was central to me leaving OSS for over a year), so I'm very familiar with the internals ofmicrobundleas well.I was investigating ezolenko/rollup-plugin-typescript2#295 and found that
microbundleis on an older version of rpt2, causing several issues in this repo.Summary
Upgrade rpt2 to v0.32.0 to fix various monorepo issues
Details
rpt2 v0.30.0 supports compiling files outside of the project directory with no additional configuration (e.g. of
rootDir) as it upgraded its dep of@rollup/pluginutilsto v4, which had a breaking change affectingcreateFilterin fix(pluginutils)!: don't add cwd to absolute or patterns that start with a glob rollup/plugins#517@rollup/pluginutilsallows transforming files outside of the project dirrpt2 v0.32.0 supports symlinks, such as with monorepos built w/ pnpm
previously, microbundle was using rpt2 v0.29.0, which is about ~1.5 years out-of-date
References
microbundleuses outdated version of rpt2 ezolenko/rollup-plugin-typescript2#295 (comment) which references Breaks when trying to import typescript outside of directory #808 and duplicated Is it possible to make this plugin transpile files from outside the root of the package (f. ex. in a monorepo setup)? ezolenko/rollup-plugin-typescript2#216 (comment)realpathto host to properly resolve monorepos / symlinks ezolenko/rollup-plugin-typescript2#332Testing
It doesn't look like
microbundle's fixtures support monorepos yet (would require setting up symlinks orpnpmetc), so as a result I didn't add a whole test suite for that which would've made this PR significantly more complex and involved in the internals of the testing set-up.Once I set-up an integration test for this in rpt2, I could contribute a similar fixture downstream here, but it may require a different CI workflow to not break the existing test set-up