xxxxxxxxxx
<!-- resources/views/alerts/alert.blade.php -->
<div class="alert {{$class}}">
<div class="alert-title">{{$title}}</div>
{{$slot}}
</div>
<!-- resources/views/index.blade.php -->
<div class="container">
@component('alerts.alert')
@slot('class')
alert-success
@endslot
@slot('title')
Success
@endslot
Message Here
@endcomponent
</div>