Fine grained update page data after form submission instead of "invalidateAll". #11802
Unanswered
BahaaZidan
asked this question in
Q&A
Replies: 1 comment
-
You probably don't want to use
|
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
Uh oh!
There was an error while loading. Please reload this page.
-
I have a page with an expensive
load
function and with lots of forms that do very small changes to the page data. I don't want to have to rerun the entireload
function after every form submission.After a couple hours of reading docs, github issues, and googling, this is what I came up with:
This seems to work. But I have a bad feeling about it 😓 . Is mutating a variable derived from data prop imperatively like this problematic in svelte-kit ? or is this fine ?
Beta Was this translation helpful? Give feedback.
All reactions