Start by changing the following
<html>
<head>
...
//@livewireStyles()
@livewireStyles
</head>
@yield('wrapper')
//@livewireScripts()
@livewireScripts
...
</html>
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I have created a base layout, with my head and footer and then have extended that layout to add in an aside that slides in. I then extended that layout to create my inner layouts – the goal is create multiple layouts that can be used.
My issue is that when I create a full-page Livewire component, and use the later layout, the wire:id is not getting set on any of the content in sections other than what is put in the {{$slot}}. This causes issues when I put filters or a search input in one of the sections as the component is not recognizing any updates to the property.
Wrapping a div around all sections and adding a wire:key does not work, as it puts that into the slot, since it's not within a section.
Is there something I can do differently to make this work, or would it simply be best to move the last layout to a blade component so I'm only using the slot?
// Example Base
<html>
<head>
...
@livewireStyles(['nonce' => csp_nonce()])
</head>
@yield('wrapper')
@livewireScripts(['nonce' => csp_nonce()])
...
</html>
// Example Wrapper
@extends('example_base')
@section('wrapper)
<div class="content_wrapper">
<div id="main">
@yield('content')
</div>
<aside id="asidePanel">
@yield('aside')
</aside>
</div>
@endsection
// Example Layout
@extends('example_wrapper')
@section('content')
<div>
<div>
@yield('left-column')
</div>
<div>
{{ $slot }}
</div>
<div>
@endsection
// Example Full-Page Livewire Component View
@section('left-column')
<input wire:model="search" type="text" />
@endsection
// the slot
<div>
@forelse($results as $result)
<div wire:key="result{{ $id }}_{{ now()->timestamp }}">{{$result}}</div>
@empty
@endforelse
<div>
@section('aside')
... // another livewire component
@endsection
I opted to use slotted blade components for my individual final layouts, and doing so solved the issue.
Please or to participate in this conversation.