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

fix(build): add css as having side effects #1481

Merged
merged 2 commits into from
Jan 31, 2023
Merged

Conversation

jinlee93
Copy link
Contributor

@jinlee93 jinlee93 commented Jan 31, 2023

Summary:

Test Plan:

@jinlee93 jinlee93 requested a review from a team January 31, 2023 19:51
Copy link
Contributor

@anniehu4 anniehu4 left a comment

Choose a reason for hiding this comment

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

tyty! could you add to the test plan how you verified the fix with alpha publishes?

@github-actions
Copy link

github-actions bot commented Jan 31, 2023

size-limit report 📦

Path Size
components 117.02 KB (0%)
styles 3.1 KB (0%)

@codecov
Copy link

codecov bot commented Jan 31, 2023

Codecov Report

Merging #1481 (93bbe05) into next (f2a6165) will decrease coverage by 0.05%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             next    #1481      +/-   ##
==========================================
- Coverage   91.54%   91.49%   -0.05%     
==========================================
  Files         279      279              
  Lines        4234     4234              
  Branches      755      755              
==========================================
- Hits         3876     3874       -2     
- Misses        356      358       +2     
  Partials        2        2              
Impacted Files Coverage Δ
src/components/Drawer/Drawer.tsx 91.04% <0.00%> (-2.99%) ⬇️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@anniehu4
Copy link
Contributor

Follow-up to #1473

"sideEffects": false,
"sideEffects": [
"lib/tokens/css/variables.css",
"lib/tokens/fonts.css"
Copy link
Contributor

Choose a reason for hiding this comment

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

What's happening on the Traject side without this?

When writing #1473, I didn't think this was necessary because Traject should be importing these explicitly.

Copy link
Contributor Author

@jinlee93 jinlee93 Jan 31, 2023

Choose a reason for hiding this comment

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

Copy link
Contributor

@ahuth ahuth Jan 31, 2023

Choose a reason for hiding this comment

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

Dang, thanks for digging into this. Looks like you were totally right @anniehu4.

There's still something I don't understand here about how Webpack handles tree shaking 😓

Seems like it is an intended thing, though: webpack/webpack#6741

@jinlee93
Copy link
Contributor Author

tyty! could you add to the test plan how you verified the fix with alpha publishes?

Yup, done

@jinlee93 jinlee93 merged commit ab07cee into next Jan 31, 2023
@jinlee93 jinlee93 deleted the jlee/addCssToSideEffects branch January 31, 2023 21:51
@jinlee93 jinlee93 mentioned this pull request Feb 14, 2023
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.

3 participants