lepikhinb / momentum-modal

MIT License
442 stars 26 forks source link

Old base component shown when navigating to route with modal #33

Closed rico closed 1 year ago

rico commented 1 year ago

I'm having a weird issue when navigating (using Inertia.get) to an URL with a Modal - the modal is displayed properly, but the base component is the one I navigated away from instead of the one defined as baseRoute for the modal.

How can that be?

No, I really don't think it is an axios version problem, I only have one :-)

 npm list axios
code@ /Users/rico/smartcode/projects/smartprax/aarepraxis/code
├─┬ @inertiajs/inertia@0.11.1
│ └── axios@0.21.4 deduped
└── axios@0.21.4
cristophergv commented 1 year ago

Hello, did you manage to solve the issue?, the same thing happens to me.

rico commented 1 year ago

@cristophergv unfortunately not.

lepikhinb commented 1 year ago

@rico Inertia.get acts the same as the Link click, so it works as expected. I might try to implement some "force" param.

rico commented 1 year ago

@lepikhinb to be honest, I don't understand why this is expected. Definitely not what I expect :-)

What exactly would a force param do? And what do you suggest I do to get the base component to update - Inertia::location() or even full page reloads using <a>?

Thanks!