Allow plugins to filter what archives Infinite Scroll supports.
Parameters
- $supported
bool Does the Archive page support Infinite Scroll.
- self::get_settings()
object IS settings provided by theme.
Changelog
- Introduced in Jetpack 2.0.0
How to use this hook
Notes
By default, Infinite Scroll is only active on your site’s home page, on archive pages, and on search pages. You can, however, use the infinite_scroll_archive_supported filter to add support to other pages, like WooCommerce’s Shop page in the example below:
function tweakjp_custom_is_support() {
$supported = current_theme_supports( 'infinite-scroll' ) && ( is_home() || is_archive() || is_search() || is_shop() );
return $supported;
}
add_filter( 'infinite_scroll_archive_supported', 'tweakjp_custom_is_support' );