block_editor_rest_api_preload_paths

FILTER wp-includes\block-editor.php (ligne 715) github
Filters the array of REST API paths that will be used to preloaded common data for the block editor.

Paramètres

Entrée :
$preload_paths, $block_editor_context
Sortie :
@param (string|string[])[]     $preload_paths        Array of paths to preload.
@param WP_Block_Editor_Context $block_editor_context The current block editor context.

Utilisation

// Modifier la valeur avec le filtre 'block_editor_rest_api_preload_paths'
add_filter('block_editor_rest_api_preload_paths', 'ma_fonction_filtre', 10, 1);

function ma_fonction_filtre($preload_paths) {
    // Modifier la valeur
    return $preload_paths;
}

Actualités

Chargement des actualités...