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

build: add sideEffects: false to package.json #3354

Merged
merged 3 commits into from
Oct 12, 2023
Merged

build: add sideEffects: false to package.json #3354

merged 3 commits into from
Oct 12, 2023

Conversation

sofisl
Copy link
Contributor

@sofisl sofisl commented Sep 26, 2023

Allows compilers to throw away unused requires.

@sofisl sofisl requested a review from a team as a code owner September 26, 2023 22:32
@product-auto-label product-auto-label bot added the size: xs Pull request size is extra small. label Sep 26, 2023
@conventional-commit-lint-gcf
Copy link

conventional-commit-lint-gcf bot commented Sep 26, 2023

🤖 I detect that the PR title and the commit message differ and there's only one commit. To use the PR title for the commit history, you can use Github's automerge feature with squashing, or use automerge label. Good luck human!

-- conventional-commit-lint bot
https://conventionalcommits.org/

Copy link
Contributor

@bcoe bcoe left a comment

Choose a reason for hiding this comment

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

This LGTM, is there a way that we could write a test for this in the library, so that we confirm it has the desired effect?

@sofisl sofisl added the automerge Merge the pull request once unit tests and other checks pass. label Oct 12, 2023
@gcf-merge-on-green
Copy link
Contributor

Merge-on-green attempted to merge your PR for 6 hours, but it was not mergeable because either one of your required status checks failed, one of your required reviews was not approved, or there is a do not merge label. Learn more about your required status checks here: https://help.github.com/en/github/administering-a-repository/enabling-required-status-checks. You can remove and reapply the label to re-run the bot.

@gcf-merge-on-green gcf-merge-on-green bot removed the automerge Merge the pull request once unit tests and other checks pass. label Oct 12, 2023
@sofisl sofisl merged commit 223a41f into main Oct 12, 2023
@sofisl sofisl deleted the sofisl-patch-2 branch October 12, 2023 17:50
@mhio
Copy link

mhio commented Oct 24, 2023

Should sideEffects be boolean false ? esbuild is complaining about it since the 128.0.0 release:

▲ [WARNING] The value for "sideEffects" must be a boolean or an array [package.json]

    ./node_modules/googleapis/package.json:9:17:
      9 │   "sideEffects": "false",
        ╵                  ^

1 warning

Webpack documents it similarly as boolean | string[]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size: xs Pull request size is extra small.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants