Computed property not updated when prop is partially reloaded? #1542
Unanswered
alancwoo
asked this question in
Help (Vue)
Replies: 1 comment
-
Did you manage to find a solution? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have a prop called
links
. When a link is deleted, the page is partially reloaded viarouter.reload({ only: ["links"] });
My list of links is rendered via a computed property
linksFiltered
which allows a user to use a dropdown to filter the list based on a number of properties:The problem I'm facing is that this doesn't seem to be recomputed, say after a link is deleted. I can see the xhr request and actually see the
links
prop updated correctly in the vue inspector, but the computed property remains the same. I've tried also forcing a manually updatedref
into the computed property but it still doesn't seem to update:I'm curious if I am doing something wrong or approaching this problem the wrong way? I am using
vue 3.2.36
and@inertiajs/vue3 1.0.6
.Edit: Also slicing the prop into a reactive ref doesn't work:
Beta Was this translation helpful? Give feedback.
All reactions