wp_load_speculation_rules action-hookWP 6.8.0

Fires when speculation rules data is loaded, allowing to amend the rules.

Usage

add_action( 'wp_load_speculation_rules', 'wp_kama_load_speculation_rules_action' );

/**
 * Function for `wp_load_speculation_rules` action-hook.
 * 
 * @param WP_Speculation_Rules $speculation_rules Object representing the speculation rules to use.
 *
 * @return void
 */
function wp_kama_load_speculation_rules_action( $speculation_rules ){

	// action...
}
$speculation_rules(WP_Speculation_Rules)
Object representing the speculation rules to use.

Changelog

Since 6.8.0 Introduced.

Where the hook is called

wp_get_speculation_rules()
wp_load_speculation_rules
wp-includes/speculative-loading.php 229
do_action( 'wp_load_speculation_rules', $speculation_rules );

Where the hook is used in WordPress

Usage not found.