Skip to content

Commit

Permalink
Fix duplicate alt tag issue - fix #104
Browse files Browse the repository at this point in the history
  • Loading branch information
riasvdv committed Mar 11, 2022
1 parent a6fe385 commit 2706a7b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions resources/views/responsiveImage.blade.php
Expand Up @@ -39,7 +39,9 @@
<img
{!! $attributeString ?? '' !!}
src="{{ $src }}"
@unless (\Illuminate\Support\Str::contains($attributeString, 'alt'))
alt="{{ $asset['title'] }}"
@endunless
@isset($width) width="{{ $width }}" @endisset
@isset($height) height="{{ $height }}" @endisset
@isset($sources)
Expand Down

0 comments on commit 2706a7b

Please sign in to comment.