Closed eoliphan closed 3 years ago
Hi and thanks for the feedback. 👍
I just push a new commit who use now createInertiaApp
new helper and it fix this issue's behavior.
https://github.com/PrestanceDesign/inertia-clojure/blob/main/examples/client-side/reagent-inertiajs/src/reagent/inertia.cljs#L36-L43
So we can close this. Best regards.
Hi, I updated my app to use createInertiaApp, etc. But calling the (start) from the :after-load causes the same issue, goes back to the home page. However, I created another method that calls (.reload Inertia) and called that from :after-load, and that seems to do the trick
Strange you got the same issue, it works well on my side for these repo examples and the Ping CRM demo, in addition to another projects.
Anyway, I change the setup https://github.com/prestancedesign/inertia-clojure/commit/256dc2c6c2aa4341ff5dc54a0af6b7b74ce5dc18 to use Inertia.reload
with the Shadow-cljs dev/after-load
hook, to handle the refresh without using var
.
This has the positive effect of decreasing the production bundle size and should fix the page redirect behaviour with some particular setup.
This isn't really a bug per-se, but solutions will really help DX. I just hacked up the following for now in a reagent client. will obviously need to extend it to handle props, etc