laravel blade check for empty string code example
Example: check empty laravel blade
@empty($products)
<p class="bg-danger text-white p-1">product</p>
@else
<p class="bg-danger text-white p-1">no product</p>
@endempty
@empty($products)
<p class="bg-danger text-white p-1">product</p>
@else
<p class="bg-danger text-white p-1">no product</p>
@endempty