woocommerce_products_will_display() WC 1.0
Check if we will be showing products or not (and not sub-categories only).
Хуков нет.
Возвращает
true/false.
Использование
woocommerce_products_will_display();
Код woocommerce_products_will_display() woocommerce products will display WC 5.0.0
function woocommerce_products_will_display() {
$display_type = woocommerce_get_loop_display_mode();
return 0 < wc_get_loop_prop( 'total', 0 ) && 'subcategories' !== $display_type;
}