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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: add mention of snapshot format change in upgrade guide #13038

Merged
merged 2 commits into from Jul 17, 2022
Merged
Changes from all 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
13 changes: 13 additions & 0 deletions docs/UpgradingToJest29.md
Expand Up @@ -14,3 +14,16 @@ See [changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md#2900) fo
## Compatibility

The supported Node versions are 14.15, 16.10, 18.0 and above.

## Snapshot format

As announced in the [Jest 28 blog post](/blog/2022/04/25/jest-28#future), Jets 29 has changed the default snapshot formatting to `{escapeString: false, printBasicPrototype: false}`.

If you want to keep the old behavior, you can set the `snapshotFormat` property to:

```diff
+ snapshotFormat: {
+ escapeString: true,
+ printBasicPrototype: true
+ }
```