From e0aee211a7a79d50ffb71b987e26a0196d89ca9e Mon Sep 17 00:00:00 2001 From: Shayokh Shuvro <56217851+ShayokhShorfuddin@users.noreply.github.com> Date: Sat, 22 Mar 2025 20:46:45 +0600 Subject: [PATCH] Update README.md Added commands for pnpm. --- README.md | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index bffa75a5..ba4754ac 100644 --- a/README.md +++ b/README.md @@ -105,14 +105,18 @@ Starting from RTL version 16, you'll also need to install npm install --save-dev @testing-library/react @testing-library/dom ``` -or - for installation via [yarn][yarn] ``` yarn add --dev @testing-library/react @testing-library/dom ``` +or, for installation via [pnpm][pnpm] + +``` +pnpm add -D @testing-library/react @testing-library/dom +``` + This library has `peerDependencies` listings for `react`, `react-dom` and starting from RTL version 16 also `@testing-library/dom`. @@ -121,10 +125,13 @@ older version of React, be sure to install version 12:_ ``` npm install --save-dev @testing-library/react@12 - - +``` +``` yarn add --dev @testing-library/react@12 ``` +``` +pnpm add -D @testing-library/react@12 +``` You may also be interested in installing `@testing-library/jest-dom` so you can use [the custom jest matchers](https://github.com/testing-library/jest-dom). @@ -656,6 +663,7 @@ Contributions of any kind welcome! [npm]: https://www.npmjs.com/ [yarn]: https://classic.yarnpkg.com [node]: https://nodejs.org +[pnpm]: https://pnpm.io [build-badge]: https://img.shields.io/github/actions/workflow/status/testing-library/react-testing-library/validate.yml?branch=main&logo=github [build]: https://github.com/testing-library/react-testing-library/actions?query=workflow%3Avalidate [coverage-badge]: https://img.shields.io/codecov/c/github/testing-library/react-testing-library.svg?style=flat-square