Skip to content
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

docs: update clashing types with jest answer #4600

Closed
Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions content/_changelogs/10.3.0.md
Expand Up @@ -23,8 +23,8 @@ _Released 6/28/2022_
fixed various issues with cookies when testing across multiple origins. Fixed
[#21363](https://github.com/cypress-io/cypress/issues/21363) and
[#20685](https://github.com/cypress-io/cypress/issues/20685).
- Updated Cypress to use posix paths to fix an issue on
Windows when a project required `node-ts`. Fixes
- Updated Cypress to use posix paths to fix an issue on Windows when a project
required `node-ts`. Fixes
[#22544](https://github.com/cypress-io/cypress/issues/22544) and
[#22297](https://github.com/cypress-io/cypress/issues/22297).
- Fixed a 9.x to 10.x migration bug where the migration tool would hang without
Expand Down
Expand Up @@ -93,6 +93,10 @@ You can also group your Cypress tests and Jest tests inside separate folders
You will need to add a `tsconfig.json` to the folder and specify the types the
files inside that folder should use.

In cypress 10, you will need to exclude `cypress.config.ts` in `tsconfig.json`.
Please see our
[Migrating to Cypress version 10.0](/guides/references/migration-guide#Clashing-types-with-Jest)

Don't forget to update your
[`specPattern`](https://docs.cypress.io/guides/references/configuration#component)
to include the new file location.
Expand Down
12 changes: 12 additions & 0 deletions content/guides/references/migration-guide.md
Expand Up @@ -714,6 +714,18 @@ plugin will need to be updated to version >= 3.10 to work with Cypress 10. Using
a previous version will result in an error when tests are ran with code coverage
enabled.

### Clashing types with Jest

Configuring your app with separate `tsconfig.json` to solve
[clashing types with jest](/guides/tooling/typescript-support#Clashing-types-with-Jest).
You will need to exclude `cypress.config.ts` in your root `tsconfig.json` file.

```json
{
"exclude": ["cypress.config.ts"]
}
```

## Migrating from `cypress-file-upload` to [`.selectFile()`](/api/commands/selectfile)

Selecting files with input elements or dropping them over the page is available
Expand Down