Caching problems after creating new resources?
What I am trying to do:
After creating a resource, the table on the ListResource page should contain the new resource.
What I did:
1. I created a resource
2. system navigated to view page of the resource
3. clicked on the resource in the navigation
4. Repeat
My issue/the error:
The first time I create a resource and navigate to the list page it shows the created resource. The second time I create a resource and navigate to the list page it does not show the created resource (only when refreshing the page). Third time I create a resource it shows the first 2 created resources.
Code:
N/A
Solution:Jump to solution
It's a Livewire feature – not Filament – and probably not much we can do about it.
11 Replies
You always use the breadcrumbs to navigate to the List Page?
Models shouldn't be cached.
No I do not use the breadcrumbs, I use the sidebar navigation
Okay, but you are using button/links on the page and not the browser navigation.
Yes
Did you enable SPA mode
->spa()
?Yes
Can you try without SPA mode?
Yes
I remembered I also have a different problem
I think it has to do with the same kind of thing
Let me check without SPA
A lot of times when I navigate through the application (pressing buttons on the sidebar navigation) it does not update the URL, which means when I refresh the page it goes to the page the url is on
Without SPA it seems to work correctly
I think this has also to do with SPA (?)
Probably.
SPA mode is buggy and not really recommended.
I did not know that! Is this in the docs?
Is this something you guys are working on or will this always be a non recommended feature?
Solution
It's a Livewire feature – not Filament – and probably not much we can do about it.