From fe461af7ec110327692f35ead738f4573e4f3b1d Mon Sep 17 00:00:00 2001 From: Johann Schopplich Date: Sun, 18 Feb 2024 15:55:52 +0100 Subject: [PATCH] perf(core): ensure image pre load event is called `once` --- packages/core/src/lazyLoad.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/src/lazyLoad.ts b/packages/core/src/lazyLoad.ts index 8dfc49f..80ccefe 100644 --- a/packages/core/src/lazyLoad.ts +++ b/packages/core/src/lazyLoad.ts @@ -134,7 +134,7 @@ export function loadImage( updateImageSrcset(image) updateImageSrc(image) onImageLoad?.(image) - }) + }, { once: true }) } export function createPlaceholderFromHash(