npm / jest-mock-extended
jest-mock-extended
What changed in jest-mock-extended 3 to 4, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-27.
1 breaking1 new APIs and options1 tooling1 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initjest-mock-extended 43 changes
Breaking changes 1
Object arguments are compared by value, so equivalent object literals match even when they are different references.
Tooling 1
The TypeScript peer dependency range now includes ^6.0.0, allowing projects using TypeScript 6.
Fixes and other changes 1
Mocked function properties regain inferred argument and return types, improving typing for overloaded methods on flat and deep mocks.
jest-mock-extended 31 changes
New APIs and options 1
Deep mocking functions with properties requires setting funcPropSupport to true, which incurs a recursive performance cost.