-
Notifications
You must be signed in to change notification settings - Fork 314
/
index.php
48 lines (45 loc) · 2.28 KB
/
index.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<?php
/**
* Plugin Name: Gutenberg Examples
* Plugin URI: https://github.com/WordPress/gutenberg-examples
* Description: This is a plugin demonstrating how to register new blocks for the Gutenberg editor.
* Version: 1.1.0
* Author: the Gutenberg Team
*
* @package gutenberg-examples
*/
defined( 'ABSPATH' ) || exit;
function gutenberg_examples_block_categories( $categories ) {
return array_merge(
$categories,
[
[
'slug' => 'jsx-examples',
'title' => 'Examples - JSX'
],
[
'slug' => 'non-jsx-examples',
'title' => 'Examples - Non JSX'
],
]
);
}
add_action( 'block_categories', 'gutenberg_examples_block_categories', 10, 2 );
require plugin_dir_path( __FILE__ ) . 'blocks-non-jsx/01-basic/index.php';
require plugin_dir_path( __FILE__ ) . 'build/blocks-jsx/01-basic-esnext/index.php';
require plugin_dir_path( __FILE__ ) . 'blocks-non-jsx/02-stylesheets/index.php';
require plugin_dir_path( __FILE__ ) . 'blocks-non-jsx/03-editable/index.php';
require plugin_dir_path( __FILE__ ) . 'build/blocks-jsx/03-editable-esnext/index.php';
require plugin_dir_path( __FILE__ ) . 'blocks-non-jsx/04-controls/index.php';
require plugin_dir_path( __FILE__ ) . 'build/blocks-jsx/04-controls-esnext/index.php';
require plugin_dir_path( __FILE__ ) . 'blocks-non-jsx/05-recipe-card/index.php';
require plugin_dir_path( __FILE__ ) . 'build/blocks-jsx/05-recipe-card-esnext/index.php';
require plugin_dir_path( __FILE__ ) . 'blocks-non-jsx/06-inner-blocks/index.php';
require plugin_dir_path( __FILE__ ) . 'build/blocks-jsx/06-inner-blocks-esnext/index.php';
require plugin_dir_path( __FILE__ ) . 'build/non-block-examples/07-slotfills-esnext/index.php';
require plugin_dir_path( __FILE__ ) . 'build/blocks-jsx/08-block-supports-esnext/index.php';
require plugin_dir_path( __FILE__ ) . 'build/non-block-examples/09-code-data-basics-esnext/index.php';
require plugin_dir_path( __FILE__ ) . 'build/blocks-jsx/10-dynamic-block/index.php';
require plugin_dir_path( __FILE__ ) . 'build/non-block-examples/format-api/index.php';
require plugin_dir_path( __FILE__ ) . 'blocks-non-jsx/plugin-sidebar/plugin-sidebar.php';
require plugin_dir_path( __FILE__ ) . 'build/blocks-jsx/meta-block/index.php';