Skip to content

Adopt pnpm as a package manager for this Repository #5327

Description

@ovflowd

Hey, you all 👋 after doing some experimentation, I wanted to ask the team (cc @nodejs/website) what you think about adopting pnpm as the package manager for this repository.

Some of the key caveats/benefits I've noticed:

  • Installing packages on CI reduced 60% from (varying 20-50seconds to blazingly 4-7 seconds)
  • Running package binaries do not require npx
  • Native monorepo support if we ever need
  • Smaller node_modules and cache footprint (making the GitHub Actions cache storage have more space) (Around 70% less footprint)

Some of the disadvantages:

  • Requires Extra Step on CI to install PNPM or use Corepack
  • Not natively installed with Node.js, so newcomers need also to install pnpm

I also want the opinion of the @nodejs/build team and the TSC @nodejs/tsc as I want to ensure that this change is not controversial nor conflicting with any of our bylaws and/or creates an adverse affect on the "npm" package manager (as if this repository does any endorsement to pnpm over npm which is not the case).

Activity

  1. mhdawson commented on Apr 26, 2023

    @mhdawson
    Member

    My initial thought is that what is most important is how easy it is to contribute a change to the website. I'm less worried about things taking a bit longer in our CI.

    Are there any significant benefits to people submitting a PR in terms of the overall time that will take them? If not I think avoiding people having to do an additional install may not be worth it.

  2. ovflowd commented on Apr 27, 2023

    @ovflowd
    MemberAuthor

    That is a great argument. And I'm in favour of it. If ultimately what matters is DX, adding another layer of dependency that requires another install on the userland can be discouraging and add extra debugging/issues to the contribution cycle towards this repository.

    And a few seconds of CI time is not a big deal. Again the idea of adopting pnpm has its pros and cons.

    And truth be said, npm is more than sufficient, and I see no issues with keeping it at the time of writing this. (NPM is darn great).

  3. ovflowd commented on Apr 27, 2023

    @ovflowd
    MemberAuthor

    I am converting this into an issue, since, hmm. This isn't really an "issue/fr" but an open discussion.

  4. locked and limited conversation to collaborators on Apr 27, 2023
  5. converted this issue into a discussion #5334 on Apr 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    infrastructureIssues/PRs related to the Repository Infra

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions