Conversation
…s in JIT The `convertDeclareComponentFacadeToMetadata` function in the JIT compiler facade previously defaulted component change detection to `OnPush`. This caused components compiled with older versions of Angular (< 22) in partial compilation mode to incorrectly use `OnPush` in JIT (e.g., in Storybook or Jest), despite working properly with `Default` in the AOT linker. Update the JIT facade to match the AOT linker behavior by checking the major version of the declaration. It defaults to `OnPush` only for components compiled with v22+ or the placeholder version, and uses `Default` change detection for older libraries. Fixes angular#71107
JeanMeche
force-pushed
the
fix-jit-onpush-default
branch
from
October 1, 2026 14:07
f06d6f1 to
cb5a954
Compare
SkyZeroZx
reviewed
Oct 1, 2026
SkyZeroZx
reviewed
Oct 1, 2026
This addresses a PR review comment by removing redundant checks that would otherwise fall through to returning true anyway.
JeanMeche
force-pushed
the
fix-jit-onpush-default
branch
from
October 1, 2026 22:07
e8fb22c to
550da5c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
convertDeclareComponentFacadeToMetadatafunction in the JIT compiler facade previously defaulted component change detection toOnPush. This caused components compiled with older versions of Angular (< 22) in partial compilation mode to incorrectly useOnPushin JIT (e.g., in Storybook or Jest), despite working properly withDefaultin the AOT linker.Update the JIT facade to match the AOT linker behavior by checking the major version of the declaration. It defaults to
OnPushonly for components compiled with v22+ or the placeholder version, and usesDefaultchange detection for older libraries.Fixes #71107