Treat reads/exceptions during equals as if the computed had performed them#90
Merged
Treat reads/exceptions during equals as if the computed had performed them#90
equals as if the computed had performed them#90Conversation
leonsenft
added a commit
to leonsenft/angular
that referenced
this pull request
Nov 27, 2024
Prevent leaking signal reads and exceptions from a custom `equal` function of a producer `computed()` to a consumer. Upstream tc39/proposal-signals#90 with a notable change: Angular does **not** track reactive reads in custom `equal` implementations.
AndrewKushnir
pushed a commit
to angular/angular
that referenced
this pull request
Jan 16, 2025
Prevent leaking signal reads and exceptions from a custom `equal` function of a producer `computed()` to a consumer. Upstream tc39/proposal-signals#90 with a notable change: Angular does **not** track reactive reads in custom `equal` implementations. PR Close #55818
AndrewKushnir
pushed a commit
to angular/angular
that referenced
this pull request
Jan 16, 2025
Prevent leaking signal reads and exceptions from a custom `equal` function of a producer `computed()` to a consumer. Upstream tc39/proposal-signals#90 with a notable change: Angular does **not** track reactive reads in custom `equal` implementations. PR Close #55818
PrajaktaB27
pushed a commit
to PrajaktaB27/angular
that referenced
this pull request
Feb 7, 2025
…r#55818) Prevent leaking signal reads and exceptions from a custom `equal` function of a producer `computed()` to a consumer. Upstream tc39/proposal-signals#90 with a notable change: Angular does **not** track reactive reads in custom `equal` implementations. PR Close angular#55818
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.
Fixes #67.
Frameworks can get other behavior by wrapping user-provided equality functions, e.g. to untrack them or to augment or report errors differently. Given that you can't un-wrap or un-hide the errors, or un-untrack the reads, this choice seemed like the most primitive one for libraries to experiment on top of that still avoids the surprising leakage behavior.