8000 Fix lazy loading of responsive images in Safari · cloudinary/cloudinary-react@c04fa42 · GitHub
[go: up one dir, main page]

Skip to content

Commit c04fa42

Browse files
committed
Fix lazy loading of responsive images in Safari
1 parent a7d202a commit c04fa42

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/components/Image/Image.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,10 @@ class Image extends CloudinaryComponent {
4242
const extendedProps = this.getExtendedProps();
4343
const {children, innerRef, ...options} = {...extendedProps, ...this.getTransformation(extendedProps)};
4444

45+
if (!this.shouldLazyLoad()){
46+
delete options.loading;
47+
}
48+
4549
return options;
4650
}
4751

0 commit comments

Comments
 (0)
0