angular/packages/core
Pawel Kozlowski 42f4f70e97 fix(core): remove signal equality check short-circuit (#53446)
The PR https://github.com/angular/angular/pull/52465 introduced short-circuit for
the signal equality invocation - with the reasoning that the equality function
should never return false for arguments with the same references. In practice it
turned out that it is rather surprising and the subsequent PR
https://github.com/angular/angular/pull/52532 added a warning when the short-circuit
was taking priority over the equality function.

Still, the presence of the short-circuit prevents people from mutating objects in
place and based on https://github.com/angular/angular/issues/52735 this is a common
and desired scenario. This change removes the short-circuit altogether and thus
fixes the mentioned issue.

We do recognize that removing short-circuit exposes developers to the potentially
surprising logic where mutated in-place change won't be propagated throug the
reactivity graph (due to the deault equality function). But we assume that this might
be less surprising / more desirable as compared to the short-circuit logic.

Fixes #52735

PR Close #53446
2023-12-08 07:05:34 -08:00
..
global build: update license headers to reference Google LLC (#37205) 2020-05-26 14:26:58 -04:00
primitives/signals fix(core): remove signal equality check short-circuit (#53446) 2023-12-08 07:05:34 -08:00
reference-manifests build: add target to generate api manifest (#52472) 2023-11-02 11:00:59 -07:00
rxjs-interop fix(core): add rejectErrors option to toSignal (#52474) 2023-10-31 14:59:26 -07:00
schematics fix(migrations): ensure we do not overwrite prior template replacements in migration (#53393) 2023-12-07 09:36:01 -08:00
src fix(core): Avoid refreshing a host view twice when using transplanted views (#53021) 2023-12-07 12:05:23 -08:00
test fix(core): remove signal equality check short-circuit (#53446) 2023-12-08 07:05:34 -08:00
testing refactor(core): Run ComponentFixture constructor in injection context (#53400) 2023-12-07 09:35:24 -08:00
BUILD.bazel build: add targets for api doc generation (#52034) 2023-10-10 16:18:50 -07:00
index.ts refactor(core): made comment structure consistent in index.ts (#43684) 2021-10-21 18:39:58 +00:00
package.json build: update node.js engines version to be more explicate about v20 support (#52448) 2023-10-31 14:18:36 -07:00
PACKAGE.md docs: add package doc files (#26047) 2018-10-05 15:42:14 -07:00
public_api.ts build: update license headers to reference Google LLC (#37205) 2020-05-26 14:26:58 -04:00