Skip to content

Commit a0bad51

Browse files
authored
fix(Image): fix no src (#1195)
1 parent c9ffcf5 commit a0bad51

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/components/Image/Image.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,10 @@ const Image = (props: ImageProps) => {
111111
!isCompressible(src) ||
112112
imgLoadingError;
113113

114+
if (!src) {
115+
return null;
116+
}
117+
114118
return (
115119
<picture className={containerClassName} data-qa={qa}>
116120
{(mobile || hideDevices.mobile) && (

0 commit comments

Comments
 (0)