You need to set the loading
attribute to eager
.
wp_get_attachment_image(
$image_id,
'full',
false,
[ 'loading' => 'eager' ], // Prevent image from being lazy loaded.
);
You need to set the loading
attribute to eager
.
wp_get_attachment_image(
$image_id,
'full',
false,
[ 'loading' => 'eager' ], // Prevent image from being lazy loaded.
);
Leave a Reply