Member-only story
Angular 21 to 22 from Jest to Vitest
Softifier
3 min read6 hours ago
What I changed, what the docs say, and the test errors that cost me the most time
Press enter or click to view image in full size
Today I moved one of my production apps from Angular 21.1.9 to 22.8.0. Three changes came with it:
ChangeDetectionStrategy.Default became Eager
• HttpClient now runs with withXhr()
• Unit tests moved from Jest to Vitest (130 test files)
The first two took little time. The third was the hard one.
1. Default is now Eager
In Angular 22, the ChangeDetectionStrategy enum has OnPush, Eager and Default. According to the API docs, Default is deprecated, equivalent to Eager, and due to be removed.…