-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
chore: remove UNOWNED flag
#17105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
chore: remove UNOWNED flag
#17105
Conversation
🦋 Changeset detectedLatest commit: 22435b2 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks promising - what I don't quite understand at the moment is how it's safe that something counts as owned as long as it has any reactions
Co-authored-by: Simon H <5968653+dummdidumm@users.noreply.github.com>
|
There is no concept of ownership any more — something is either connected (in which case it will be notified of changes to its dependencies, and will in turn notify its dependents) or it isn't. We don't need to care if a derived is owned or not |
This makes good on my threat in #17102 (comment) to sort out all the convoluted nonsense around
UNOWNEDandDISCONNECTEDderiveds. We've made this far more complicated than it needs to be. All we need to do is push the current signal to its dependencies'reactionswhen the signal is connected to the graph, and skip doing so when it isn't.Most benchmarks are unaffected, but where there is a significant effect, this branch is much faster.
results of `pnpm bench:compare`
Before submitting the PR, please make sure you do the following
feat:,fix:,chore:, ordocs:.packages/svelte/src, add a changeset (npx changeset).Tests and linting
pnpm testand lint the project withpnpm lint