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

refactor(build): update to use rollup #2327

Merged
merged 12 commits into from
Sep 23, 2022
Merged

Conversation

joshblack
Copy link
Member

@joshblack joshblack commented Sep 12, 2022

This is a follow-up to #2257 after #2314 landed to remove circular imports.

This PR specifically removes the compile step in scripts/build in favor of using Rollup. It uses the existing rollup setup (specifically with babel) with the potential to move towards another plugin (like @rollup/plugin-typescript) in the future in order to further consolidate the build step (like generating declaration files)

I tried my best to verify all the support export paths/patterns but would love a second look at these to see if I missed any!

Import Format Path Status
@primer/react CommonJS ./lib/index.js
@primer/react ESM ./lib-esm/index.js
@primer/react/drafts CommonJS ./lib/drafts/index.js
@primer/react/drafts ESM ./lib-esm/drafts/index.js
@primer/react/deprecated CommonJS ./lib/deprecated/index.js
@primer/react/deprecated ESM ./lib-esm/deprecated/index.js

@changeset-bot
Copy link

changeset-bot bot commented Sep 12, 2022

🦋 Changeset detected

Latest commit: 10b6db0

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@primer/react Patch

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

@github-actions
Copy link
Contributor

github-actions bot commented Sep 12, 2022

size-limit report 📦

Path Size
dist/browser.esm.js 77.08 KB (+1.72% 🔺)
dist/browser.umd.js 77.68 KB (+1.67% 🔺)

@joshblack joshblack temporarily deployed to github-pages September 12, 2022 23:01 Inactive
@joshblack joshblack closed this Sep 13, 2022
@joshblack joshblack reopened this Sep 20, 2022
@joshblack joshblack temporarily deployed to github-pages September 20, 2022 20:31 Inactive
@joshblack joshblack temporarily deployed to github-pages September 20, 2022 21:01 Inactive
@joshblack joshblack temporarily deployed to github-pages September 21, 2022 15:12 Inactive
@joshblack joshblack temporarily deployed to github-pages September 21, 2022 15:42 Inactive
@joshblack joshblack marked this pull request as ready for review September 21, 2022 15:48
@joshblack joshblack requested review from a team and mperrotti September 21, 2022 15:48
@joshblack joshblack temporarily deployed to github-pages September 21, 2022 16:21 Inactive
@joshblack joshblack temporarily deployed to github-pages September 22, 2022 16:21 Inactive
@joshblack joshblack temporarily deployed to github-pages September 22, 2022 22:09 Inactive
Copy link
Contributor

@colebemis colebemis left a comment

Choose a reason for hiding this comment

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

This seems like a great incremental step towards fixing our bundle issues. Great work, @joshblack!

@joshblack joshblack merged commit df2a834 into main Sep 23, 2022
@joshblack joshblack deleted the refactor/update-build-to-rollup branch September 23, 2022 15:42
@primer-css primer-css mentioned this pull request Sep 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants