Skip to content

Update installation.md #897

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

Merged
merged 1 commit into from
Sep 9, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions docs/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ your hook. We currently support two different renderers:
- `react-test-renderer`
- `react-dom`

When using standard import for this library (show below), we will attempt to auto-detect which
When using standard import for this library (see below), we will attempt to auto-detect which
renderer you have installed and use it without needing any specific wiring up to make it happen. If
you have both installed in your project, and you use the standard import (see below) the library
will default to using `react-test-renderer`.
Expand All @@ -63,7 +63,7 @@ import { renderHook } from '@testing-library/react-hooks'
### Act

Each render also provides a unique [`act` function](https://reactjs.org/docs/test-utils.html#act)
that cannot be used with other renderers. In order to simplify with `act `function you need to use,
that cannot be used with other renderers. In order to simplify which `act `function you need to use,
we also export the correct one alongside the detected renderer for you:

```js
Expand All @@ -73,8 +73,8 @@ import { renderHook, act } from '@testing-library/react-hooks'
## Being specific

Auto-detection is great for simplifying setup and getting out of your way, but sometimes you do need
a little but more control. If a test needs requires a specific type of environment, the import can
be appended to force a specific renderer to be use. The supported environments are:
a little bit more control. If a test needs a specific type of environment, the import can
be appended to force a specific renderer to be used. The supported environments are:

- `dom`
- `native`
Expand Down