get named slots in components laravel code example
Example: multiple slots laravel components
<x-sidebar>
<x-slot name="avatar">
<img src="/image/user-avatar.png" />
</x-slot>
...........
</x-sidebar>
<!-- Now inside /resources/views/components/sidebar.blade.php -->
<div>
{{ $avatar }}
</div>
<div class="collapse list-unstyled">
{{ $slot }}
</div>