From a437596880f4ddb46a284c0522030cd4b1ca1237 Mon Sep 17 00:00:00 2001 From: Matan Borenkraout Date: Wed, 24 Apr 2024 10:53:26 +0300 Subject: [PATCH 1/4] docs: move dtl to peerdeps for rtl --- docs/react-testing-library/intro.mdx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/docs/react-testing-library/intro.mdx b/docs/react-testing-library/intro.mdx index 9cf2a553..59a4b389 100644 --- a/docs/react-testing-library/intro.mdx +++ b/docs/react-testing-library/intro.mdx @@ -9,19 +9,22 @@ APIs for working with React components. ## Installation +To get started with `React Testing Library`, you'll need to install it together +with it's peerDependency `@testing-library/dom`: + ```bash npm2yarn -npm install --save-dev @testing-library/react +npm install --save-dev @testing-library/react @testing-library/dom ``` ### With TypeScript -To get full type coverage, you need to install the types for `react-dom` as well: +To get full type coverage, you need to install the types for `react-dom` as +well: ```bash npm2yarn npm install --save-dev @testing-library/react @types/react-dom ``` - [gh]: https://github.com/testing-library/react-testing-library ## The problem From 68bacc87bf89c2403f3eaff78f99c7cb3b7a33f0 Mon Sep 17 00:00:00 2001 From: Matan Borenkraout Date: Fri, 26 Apr 2024 18:39:39 +0300 Subject: [PATCH 2/4] add @types/react-dom to the types install Co-authored-by: Sebastian Silbermann --- docs/react-testing-library/intro.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/react-testing-library/intro.mdx b/docs/react-testing-library/intro.mdx index 59a4b389..347b03ff 100644 --- a/docs/react-testing-library/intro.mdx +++ b/docs/react-testing-library/intro.mdx @@ -22,7 +22,7 @@ To get full type coverage, you need to install the types for `react-dom` as well: ```bash npm2yarn -npm install --save-dev @testing-library/react @types/react-dom +npm install --save-dev @testing-library/react @testing-library/dom @types/react-dom ``` [gh]: https://github.com/testing-library/react-testing-library From daf9c6082845a5e38a3f53f255faa82c5933486f Mon Sep 17 00:00:00 2001 From: Matan Borenkraout Date: Fri, 26 Apr 2024 18:39:53 +0300 Subject: [PATCH 3/4] fix typo Co-authored-by: Sebastian Silbermann --- docs/react-testing-library/intro.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/react-testing-library/intro.mdx b/docs/react-testing-library/intro.mdx index 347b03ff..1ef3c2fe 100644 --- a/docs/react-testing-library/intro.mdx +++ b/docs/react-testing-library/intro.mdx @@ -10,7 +10,7 @@ APIs for working with React components. ## Installation To get started with `React Testing Library`, you'll need to install it together -with it's peerDependency `@testing-library/dom`: +with its peerDependency `@testing-library/dom`: ```bash npm2yarn npm install --save-dev @testing-library/react @testing-library/dom From 23152c1d955a6eb91064a5d00753f8de0eaf2eb2 Mon Sep 17 00:00:00 2001 From: Matan Borenkraout Date: Mon, 3 Jun 2024 17:40:45 +0300 Subject: [PATCH 4/4] fix broken merge --- docs/react-testing-library/intro.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/react-testing-library/intro.mdx b/docs/react-testing-library/intro.mdx index 1ef3c2fe..7d8d026c 100644 --- a/docs/react-testing-library/intro.mdx +++ b/docs/react-testing-library/intro.mdx @@ -18,11 +18,11 @@ npm install --save-dev @testing-library/react @testing-library/dom ### With TypeScript -To get full type coverage, you need to install the types for `react-dom` as +To get full type coverage, you need to install the types for `react` and `react-dom` as well: ```bash npm2yarn -npm install --save-dev @testing-library/react @testing-library/dom @types/react-dom +npm install --save-dev @testing-library/react @testing-library/dom @types/react @types/react-dom ``` [gh]: https://github.com/testing-library/react-testing-library