Component search stopped working properly

It is really strange, but it is not possible to create component or even pull changes from git with new components without explicitly entering component lbindings into "livewire-components.php" in bootstrap/cache. Not sure in which version it stopped working, but it seems in some latest ones.
If I do not map component in "livewire-components.php", Livewire is just picking some random components and trying to render instead of what you asked to render…
And it was working so well before.

this is odd @Dimonka2!
can you provide any code example or errors from the log?

I found the reason and it is actually interesting to remember.
I stopped long time ago creating components via console, because many thing I just want to reuse and not type again. So basically I am copying some part of another component into a new livewire component and change namespace and class name. Works perfectly, but… If you forget to change class name or namespace it got cached in two places and if you do not know about it - it is hard to understand what is going on, why something else is rendered and so on.
To fix it is enough to search in caches all appearance of the full component class name and delete those lines. It will get cached again with the right name.

Now I have another completely weird situation - I am not able to mount a model… Whatever names I used - getting an new empty model in mount method. It is really nice if magic works and could be a horror if not… :slight_smile:
Update on the last issue - that was just my very stupid mistake. Taking it back - magic works! :smiley:

Cool @Dimonka2 :clap:

I’m wonder whether $ artisan clear-compiled or $ composer dumpautoload didn’t solve those issues for you when creating/moving classes by hand.

My guess is that clear-compiled will not affect the Livewire component name cache.