Level 75
You should see in the network tab. For screen, place result in a div.
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Hello, I have this code in my livewire component
$franchiseList = $this->getFranchiseList();
I would like to emit $franchiseList to the browser
I tried by adding this to my component
$this->emit('getFranchiseList');
and this to my blade-view component
<script>
let data = null;
document.addEventListener('livewire:load', () => {
@this.on('getFranchiseList', () => {
data = @this;
console.log(data);
})
})
</script>
but I only get this on the console
Proxy {}
How can I get the result of getFranchiseList to the console?
the return type is
Illuminate\Pagination\LengthAwarePaginator {#1474 ▼
#items: Illuminate\Database\Eloquent\Collection {#1422 ▶}
#perPage: 10
#currentPage: 1
Please or to participate in this conversation.