Snippets: Conditionally Alter Excerpt Length

add_filter( 'wpex_get_excerpt_defaults', function( $args ) {
	if ( is_front_page() ) {
		$args['length'] = 10; // Excerpt length of 10 words for homepage only
	}
	return $args;
} );