Skip to content

Commit

Permalink
docs: how to update tsconfig for vitest matchers extension (#624)
Browse files Browse the repository at this point in the history
  • Loading branch information
mibcadet authored Aug 23, 2024
1 parent fdee851 commit 8fd402a
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,20 @@ import '@testing-library/jest-dom/vitest'
setupFiles: ['./vitest-setup.js']
```

Also, depending on your local setup, you may need to update your `tsconfig.json`:

```json
// In tsconfig.json
"compilerOptions": {
...
"types": ["vitest/globals", "@testing-library/jest-dom"]
},
"include": [
...
"./vitest.setup.ts"
],
```

[vitest]: https://vitest.dev/
[vitest setupfiles]: https://vitest.dev/config/#setupfiles

Expand Down

0 comments on commit 8fd402a

Please sign in to comment.