wphooks.info - block_editor_preload_paths

block_editor_preload_paths

(trunk - 5.1-alpha-44286)

*** New in trunk ***

The hook occurs in the following file:

wp-admin/edit-form-blocks.php:
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
/**
 * Preload common data by specifying an array of REST API paths that will be preloaded.
 *
 * Filters the array of paths that will be preloaded.
 *
 * @since 5.0.0
 *
 * @param array  $preload_paths Array of paths to preload.
 * @param object $post          The post resource data.
 */
$preload_paths = apply_filters( 'block_editor_preload_paths', $preload_paths, $post );

/*
 * Ensure the global $post remains the same after API data is preloaded.
 * Because API preloading can call the_content and other filters, plugins
 * can unexpectedly modify $post.
 */
$backup_global_post = $post;

$preload_data = array_reduce(