apply_filters( 'relevanssi_sku_boost', float $boost )
Increases the weight of the _sku
field in WooCommerce.
Parameters
$boost
(float) The multiplier used to multiply _sku
field matches.
More information
If you want to make matches in the _sku
custom field more prominent, you can use this filter hook to make them weigh heavier. This is a simple relevanssi_match
filter hook, but using this requires Relevanssi Premium.
Adding this to your theme functions.php
would increase the SKU multiplier to 5:
add_filter( 'relevanssi_sku_boost', function( $boost ) { return 5; } );