wp_min_priority_img_pixels хук-фильтрWP 6.3.0

Filters the minimum square-pixels threshold for an image to be eligible as the high-priority image.

Использование

add_filter( 'wp_min_priority_img_pixels', 'wp_kama_min_priority_img_pixels_filter' );

/**
 * Function for `wp_min_priority_img_pixels` filter-hook.
 * 
 * @param int $threshold Minimum square-pixels threshold.
 *
 * @return int
 */
function wp_kama_min_priority_img_pixels_filter( $threshold ){

	// filter...
	return $threshold;
}
$threshold(int)
Minimum square-pixels threshold.
По умолчанию: 50000

Список изменений

С версии 6.3.0 Введена.

Где вызывается хук

wp_maybe_add_fetchpriority_high_attr()
wp_min_priority_img_pixels
wp_get_loading_optimization_attributes()
wp_min_priority_img_pixels
wp-includes/media.php 6244
$wp_min_priority_img_pixels = apply_filters( 'wp_min_priority_img_pixels', 50000 );
wp-includes/media.php 6125
$wp_min_priority_img_pixels = apply_filters( 'wp_min_priority_img_pixels', 50000 );

Где используется хук в WordPress

Использование не найдено.