Skip to content

Commit b42457e

Browse files
authored
Merge pull request #13 from indykoning/patch-4
Fallback if entry is missing
2 parents 60fe6d3 + 743939a commit b42457e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

resources/views/partials/head.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<script>
22
window.responsiveResizeObserver = new ResizeObserver(async (entries) => {
33
entries.forEach(entry => {
4-
let imgWidth = entry.devicePixelContentBoxSize[0].inlineSize;
4+
let imgWidth = entry?.devicePixelContentBoxSize?.[0]?.inlineSize || 0;
55
66
if (imgWidth === 0) {
77
return;

0 commit comments

Comments
 (0)