Docs: Clarify the path usage register_block_type_from_metadata

The filename passed with the first param must end with `block.json`.

Fixes #53806.
Props coreyw, costdev.


Built from https://develop.svn.wordpress.org/trunk@52012


git-svn-id: http://core.svn.wordpress.org/trunk@51603 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
gziolo 2021-11-04 16:03:57 +00:00
parent 56e4bf827d
commit e4da863a6f
2 changed files with 2 additions and 1 deletions

View File

@ -213,6 +213,7 @@ function get_block_metadata_i18n_schema() {
* *
* @param string $file_or_folder Path to the JSON file with metadata definition for * @param string $file_or_folder Path to the JSON file with metadata definition for
* the block or path to the folder where the `block.json` file is located. * the block or path to the folder where the `block.json` file is located.
* If providing the path to a JSON file, the filename must end with `block.json`.
* @param array $args Optional. Array of block type arguments. Accepts any public property * @param array $args Optional. Array of block type arguments. Accepts any public property
* of `WP_Block_Type`. See WP_Block_Type::__construct() for information * of `WP_Block_Type`. See WP_Block_Type::__construct() for information
* on accepted arguments. Default empty array. * on accepted arguments. Default empty array.

View File

@ -16,7 +16,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '5.9-alpha-52011'; $wp_version = '5.9-alpha-52012';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.