-
Couldn't load subscription status.
- Fork 2
Open
Labels
enhancementNew feature or requestNew feature or request
Description
The Problem
There is a Gutenberg\BlockInterface, and a common way of creating one seems to be by using a map returned by parse_blocks(). Unfortunately, there's nothing right now that could allow the creation of a block from such a map. There's no way at all to abstract block initialization.
Suggested Solution
- Add a
BlockFactoryInterfacethat would accept the key parameters for blocks separately and with proper type declarations. - Add a
ConfigBasedBlockFactoryInterfacethat would accept anarraymap of values from one of the items ofparse_blocks(). This allows easy creation from configuration, based on WP config key conventions.
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request