Skip to content

Commit 06eb00e

Browse files
omeroseKent C. Dodds
andcommitted
docs: add correct README instructions for tsconfig (#54)
* 📝 Add correct README instructions for tsconfig Followed the instructions and it didn't work with recent changes to official instructions from Cypress-typescript I installed last week. So these documentation will help out. I also found the types file to be handy, so I added it into the README * Update README.md Co-authored-by: Kent C. Dodds <[email protected]>
1 parent fd3b321 commit 06eb00e

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,17 @@ added as follows in `tsconfig.json`:
8888
}
8989
```
9090

91+
Or if tsconfig.json has a `baseUrl` of `../node_modules` as recommended in
92+
the official Cypress documentation use:
93+
94+
```json
95+
{
96+
"compilerOptions": {
97+
"types": ["cypress", "@testing-library/cypress/typings"]
98+
}
99+
}
100+
```
101+
91102
## Usage
92103

93104
`cypress-testing-library` extends Cypress' `cy` command.
@@ -102,6 +113,8 @@ You can now use all of `dom-testing-library`'s `getBy`, `getAllBy`, `queryBy`
102113
and `queryAllBy` commands.
103114
[See the `dom-testing-library` docs for reference](https://testing-library.com)
104115

116+
You can find [all Library definitions here](./typings/index.d.ts).
117+
105118
To show some simple examples (from
106119
[cypress/integration/commands.spec.js](cypress/integration/commands.spec.js)):
107120

0 commit comments

Comments
 (0)