2 LWA on page -> bad interference #53
-
|
I have two LWAs on the same page. One to search and complete for "submitters" and one to search and complete for "projects". When I load the page with the form and type a name into the search for submitters and then select one of those submitters that are shown to me, the drop down with the result-rows shortly disappears and shows up again shortly after. If I click to select one of the presented submitters again, it then works. I can then also go to the LWA for projects and search for a project and it will work on the first try. Investigating it further, I found my browsers network tab would send this update the first time I'd select a submitter:
And on the 2nd click of the exact same result row, I'd get
If I wouldn't have the project LWA in my blade, my code works as intendend from the get go. I don't understand why my selection of a submitter triggers an update for something project related and unintended. How can I fix this? Here is my blade file for context: |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
I found the mistake I made. In my Component, I initially used: So it wasn't null so the update was send. Changing it to: Solved the issue. Of course I find the solution hours after I posted here, when I didn't find it in the last 3 days constantly working on it. Forgive me, I am new to Laravel and Livewire. |
Beta Was this translation helpful? Give feedback.
I found the mistake I made. In my Component, I initially used:
So it wasn't null so the update was send. Changing it to:
Solved the issue. Of course I find the solution hours after I posted here, when I didn't find it in the last 3 days constantly working on it. Forgive me, I am new to Laravel and Livewire.