How to fix the "This project is configured to use Yarn" error on pnpm install
Last updated on October 08, 2023
![How to fix the "This project is configured to use Yarn" error on pnpm install](/_next/image?url=https%3A%2F%2Fwp.codingbeautydev.com%2Fwp-content%2Fuploads%2F2023%2F10%2Fpnpm-install-this-project-is-configured-to-use-yarn-error.png&w=3840&q=75)
The "This project is configured to use Yarn" error happens in pnpm install
when you have a field in your package.json
file that specifies Yarn as the package manager.
The package.json
field may have come about when you ran a yarn set version ...
command, for example, yarn set version stable
to set up Yarn Berry, or yarn set version berry
to migrate from Yarn v1 to Yarn Berry.
![](/_next/image?url=https%3A%2F%2Fwp.codingbeautydev.com%2Fwp-content%2Fuploads%2F2023%2F10%2Fimage-11-1024x627.png&w=3840&q=75)
Fix "This project is configured to use Yarn" error
To fix the this pnpm install
usage error, simply remove the "packageManager"
field from package.json
:
![](/_next/image?url=https%3A%2F%2Fwp.codingbeautydev.com%2Fwp-content%2Fuploads%2F2023%2F10%2Fimage-13-1024x347.png&w=3840&q=75)
Once you do that, pnpm install
will run properly.
![](/_next/image?url=https%3A%2F%2Fwp.codingbeautydev.com%2Fwp-content%2Fuploads%2F2023%2F10%2Fimage-14-1024x453.png&w=3840&q=75)
See also
- How to quickly fix the "Cannot read property 'then' of undefined" error in JavaScript
- How to Fix the "Unexpected strict mode reserved word 'yield'" Error in JavaScript
- How to easily fix the EAI_AGAIN error in NPM, Yarn, or PNPM
- How to quickly fix the ERR_OSSL_EVP_UNSUPPORTED error in Node.js
- How to fix the "__dirname is not defined in ES module scope" error in JavaScript
- How to easily fix the "Cannot read property 'classList' of null" error in JavaScript