beapi-frontend-framework icon indicating copy to clipboard operation
beapi-frontend-framework copied to clipboard

6.0 patterns

Open Rahe opened this issue 3 years ago • 0 comments
trafficstars

In WP 6.0 patterns will be automatically loaded by the website CF https://github.com/WordPress/gutenberg/blob/b8aa52dc4a1fe3887be27d5f3d1a77b409dc8750/lib/compat/wordpress-6.0/block-patterns.php#L77

We only need to put the files into patterns/{file}.php. The headers of the pattern file will determine the name and description cf :

		'title'         => 'Title',
		'slug'          => 'Slug',
		'description'   => 'Description',
		'viewportWidth' => 'Viewport Width',
		'categories'    => 'Categories',
		'keywords'      => 'Keywords',
		'blockTypes'    => 'Block Types',
		'inserter'      => 'Inserter',

We do not need to register by hand.

Rahe avatar Apr 27 '22 16:04 Rahe